Write a program that Will short thee integers .the integers are entered from the keyboard and stored in variable num1,num2,num3 respectively. The program sorts the numbers so that num1<=num2<=num3.
Write a program that read an integer and display all its smallest factors. example if the input integer 120,then the output should be as follows: 2,2,2,3,5.
Write a function that determines whether an integer is a prime number.
Suppose you work for an employer that sells vehicles and your employer instructs you to design a program using the C++ language to determine the car that corresponds to the price that your program calculated. The price of the car is determined by adding three(3) prices: which are engine price, color price, and the price based on the color of the car. The engine price ranges between R500 000 – R2000000-00. The colour of the car ranges between R7000 – R10000
The price based on the power of the car ranges between R300 000 – R600 000. If the sum of the three(3) prices is between R700 000 – R1000000, the program must display that the car is in the range of a VW Golf 8 GTI. If the sum of the three(3) prices is between R1100000-1800000, the program must display that the car is in the range of a Mercedes Benz GLC63s. If the sum of the three(3) prices is between R1900 000 – R2500000, the program must display that the car is in a range of a BMW M8 challenger. DESIGN YOUR A PSEUDOCODE
Now, imagine your younger brother is working in a project with you. Both of you need to
solve negative number issue input by user. But you want to restrict information type
which can be send as error notification by your brother. So, write a program to handle the
scenario.
Write a C++ program for the following specification: Create a class Fuzzy with two
data members: x of type integer and memx of type float. memx should range from 0 to 1. Implement the operator overloading for the operators: &, I and ~. i. Operator function for & should return the Fuzzy object with minimum memx, after checking the equality of data member x in both objects.
Sample Data:
f1 (10,0.5) f2= (10,0.2)
f1&f2= (10,0.2) ii. Operator function for should return the Fuzzy object with 1-memx..
Sample Data:
f2=(10,0.2) ~f2=(10,0.8)
Implement the appropriate member functions to get the input and print the output.
Note: In & operator overloading, if x is not equal, then return fuzzy object (0,0)
Create a class Time with data members – Hours(int), Minutes(int) and Seconds(int). Include two
constructors – (i) to initialize the data members to zero, and (ii) to initialize the data members with
the values passed as arguments. Include two member functions – (i) AddTime() to add two objects
passed as parameters and set the invoking object with this result (ii) DispTime() to display the time
in the format hh:mm:ss. The main() program should create two initialized Time objects and one that
is not initialized. Add the two initialized values leaving the result in the third Time object. Display the
values of the third object.