partA q1 cpp

Create a new C++ program named “partA_q1.cpp”

Write a program in C++ to calculate and display the kinetic energy (J) of a 2.4 kg mass when the user provides its velocity (km/h). Use the following equation:

1 =2× ×(

Question 2

Create a new C++ program named “partA_q2.cpp”

× 1000 2 60×60 )

Write a program in C++ that will let the user know whether a number that they enter is a multiple of eleven. Hint: If there is no remainder after dividing a number by eleven, that number is ***** multiple of eleven.

Question 3 [7 marks]

Create a new C++ program named “partA_q3.cpp”

Write another program that performs the same task as Question 2, but this program should allow the user to test another number, if they wish to do so.

(Hint: Modify your code from Question 2.)

Question 4 [15 marks] Create a new C++ program named “partA_q4.cpp”

Write a C++ program that uses a for() loop to calculate and display the sum of the following series, for a given the number of terms (n). n is to be provided by the user and must be greater than four.

= 1 + 1 + 1 +⋯+ 1

sin (1) sin (2) sin (3) sin (n) ππππ

Tags: No tags