2023 For this lab you have to solve four required problems Some problem requires from you to | Assignment Collections

Computer Science 2023 Lab#3

2023 For this lab you have to solve four required problems Some problem requires from you to | Assignment Collections

 

  1. For this lab, you have to solve four required problems. Some problem requires from you to input some data and do some calculation.
  2. There is a bonus problem (the last one). It is optional
  3. Each problem should be solved inside its own main function with comments in between.
  4. Think about the possible data types for each data in every problem.
  5. Choose names for your variables that make sense, don’t use any  variable name that is one character only. Use good, multi-character,  meaningful identifiers (variables) names. There is a 5% penalty for not  doing that.
  6. Document your work by putting comments at the top of your program.  The possible comments that you need for this program are the program  prolog (name of the programmer, your class and section, the date when  you finished working on the program and the purpose of the program).   There is a 5% penalty for not doing that.
  7. In addition to that, you have to write some comments between the  lines of the code to show why you write your code this way. Remember  that comments in Python are either:
    • Starts with // in case the comment is one line only.
    • Or it is between /*  */ if the comment is taking more than one line.

Problem 1: Lake Length

To approximate the length  of a lake, a surveyor starts at one end of the lake and walks 245  yards. He then turns 110º and walks 270 yards until he arrives at the  other end of the lake. Approximately how long is the lake?

———————————–

Problem 2: President Age

Ask  the user to input his/her age. The check if the user’s age makes  him/her eligible to be a president of the United State of America. As  specified in the U.S. Constitution, a person must be aged 35 or over to  be a president

————————————

Problem 3: Profit vs. Lost

Write a program that asks the user to input a product cost price and its selling price (two inputs).  Then check if the seller makes a profit or loss from that product, in  addition, to calculate the total profit or total loss rounded to 2  decimals digits.

———————————————————-

Problem 4: Circles Overlap

Write  a program to determine whether or not two circles touch each other,  overlap with each other, or not overlap with each other. your program  should work like the following

  • Ask the user to input the X-coordinate of the center of the first circle.
  • Ask the user to input the Y-coordinate of the center of the first circle.
  • Ask the user to input the radius of the first circle.
  • Ask the user to input the X-coordinate of the center of the second circle.
  • Ask the user to input the Y-coordinate of the center of the second circle.
  • Ask the user to input the radius of the second circle

Based on these inputs, can you determine if the two circles are :

  • Touch each other,
  • Overlap with each other 
  • Not overlap with each other

Show a proper message for each case.

Test Your program using these 3 cases:

Case #1 :
Input:
3
4
5
14
18
8
Output : Circles do not touch each other.

Case #2 :
Input:
2
3
12
15
28
20
Output : Circles intersect with each other.

Case #3 :
Input:
-10
8
30
14
-24
10
Output : Circle touch each other.

————————————–

Problem 5:  Basketball Players

Two players stand on a basketball court. The angles of elevation from the foot of each player to the basket (which is 10′ high) are 40 and 50 degrees. How far apart are the players from each other? Check the following diagram.

 

We give our students 100% satisfaction with their assignments, which is one of the most important reasons students prefer us to other helpers. Our professional group and planners have more than ten years of rich experience. The only reason is that we have successfully helped more than 100000 students with their assignments on our inception days. Our expert group has more than 2200 professionals in different topics, and that is not all; we get more than 300 jobs every day more than 90% of the assignment get the conversion for payment.

Place Order Now

#write essay #research paper #blog writing #article writing #academic writer #reflective paper #essay pro #types of essays #write my essay #reflective essay #paper writer #essay writing service #essay writer free #essay helper #write my paper #assignment writer #write my essay for me #write an essay for me #uk essay #thesis writer #dissertation writing services #writing a research paper #academic essay #dissertation help #easy essay #do my essay #paper writing service #buy essay #essay writing help #essay service #dissertation writing #online essay writer #write my paper for me #types of essay writing #essay writing website #write my essay for free #reflective report #type my essay #thesis writing services #write paper for me #research paper writing service #essay paper #professional essay writers #write my essay online #essay help online #write my research paper #dissertation writing help #websites that write papers for you for free #write my essay for me cheap #pay someone to write my paper #pay someone to write my research paper #Essaywriting #Academicwriting #Assignmenthelp #Nursingassignment #Nursinghomework #Psychologyassignment #Physicsassignment #Philosophyassignment #Religionassignment #History #Writing #writingtips #Students #universityassignment #onlinewriting #savvyessaywriters #onlineprowriters #assignmentcollection #excelsiorwriters #writinghub #study #exclusivewritings #myassignmentgeek #expertwriters #art #transcription #grammer #college #highschool #StudentsHelpingStudents #studentshirt #StudentShoe #StudentShoes #studentshoponline #studentshopping #studentshouse #StudentShoutout #studentshowcase2017 #StudentsHub #studentsieuczy #StudentsIn #studentsinberlin #studentsinbusiness #StudentsInDubai #studentsininternational