Question
The Sentence Visualizer Creates Of A Visualization Of The Sentence Then The Visualize Button Is Clicked. It Will Draw A Circle For A Vowel, And
The Sentence Visualizer Creates Of A Visualization Of The Sentence Then The Visualize Button Is Clicked. It Will Draw A Circle For A Vowel, And It Will Draw A Square For A Consonant. There Will Be A Blank Space For All Other Characters. The Color Of The
The sentence visualizer creates of a visualization of the sentence then the visualize button is clicked. It will draw a circle for a vowel, and it will draw a square for a consonant. There will be a blank space for all other characters. The color of the shapes, will be determined the "Vowel Color" color picker, and the "Consonant Color" color picker. When the users change those colors, the color in the visualization should change too.
Please implement visualize, changeVowelColor and ChangeConsonantColor function with the behavior described above.
HTML File:
Sentence visualizer Sentence visualizer
Sentence Vowel Color Consonant Color
JAVASCRIPT File:
function visualize(){ } function changeVowelColor(event){ } function changeConsonantColor(event){ }
The Accent Points page creates a star with a random number of points when the page loads. When the user clicks the circle button, please draw a black circle of radius 10 at every point of the star. When the user clicks square, please draw blue square with side 10 at every point of the star.
Please implement accentCircle and accentSquare functions with the behavior described above.
HTML File:
Polygon Accent function setup(){ let points = 2*Math.round(Math.random()*7 + 3); let pointString =""; const r1 = 150; const r2 = 100; const cx = 250; const cy = 250; for(let i = 0; i let r = i%2==0?r1:r2; let x = cx + r*Math.cos(i*2*Math.PI/points); let y = cy + r*Math.sin(i*2*Math.PI/points); pointString += `${x},${y} `; } let str = `"`; document.querySelector("#star").innerHTML = str; } Accent Points
JAVASCRIPT File:
function accentCircle(){ } function accentSquare(){ }
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started