Answered step by step
Verified Expert Solution
Question
1 Approved Answer
how to solve the problem with c++? 3. [20 pts a) 4 pts b) 8 pts c) 8pts] Graphics For this question you may assume
how to solve the problem with c++?
3. [20 pts a) 4 pts b) 8 pts c) 8pts] Graphics For this question you may assume that a graphics project has been set up for you. a) Write a function prototype for a function called draw_balloon that takes as an argument a Point P and a double scale. This function does not return anything. b) Write the function draw_balloon. Your function should draw a "balloon", that is, a circle centered at the given Point P and with a radius scale. At the bottom of the circle draw a line pointing straight down with length scale. See picture below. c) Write a snippet for the ccc_win_main. Ask the user how many times he wants to click and store his answer in an int variable n. Then ask the user n times to click somewhere. Each time the user clicks his mouse, use your function from part a) to draw a balloon at the click point. The scale of the balloon will be defined as the y coordinate of the click point. 3. [20 pts a) 4 pts b) 8 pts c) 8pts] Graphics For this question you may assume that a graphics project has been set up for you. a) Write a function prototype for a function called draw_balloon that takes as an argument a Point P and a double scale. This function does not return anything. b) Write the function draw_balloon. Your function should draw a "balloon", that is, a circle centered at the given Point P and with a radius scale. At the bottom of the circle draw a line pointing straight down with length scale. See picture below. c) Write a snippet for the ccc_win_main. Ask the user how many times he wants to click and store his answer in an int variable n. Then ask the user n times to click somewhere. Each time the user clicks his mouse, use your function from part a) to draw a balloon at the click point. The scale of the balloon will be defined as the y coordinate of the click pointStep 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