To store a number that contains no decimal places.
write a generic C++ program that will enable students to calculate the area and volume of a trapezium. The program should prompt a student to enter the values for the length of the parallel sides and is perpendicular distance between the parallel sides respectively. The program should calculate and display the area and volume of the trapezium.
Secret Message - 2
Given a string, write a program to print a secret message that replaces characters with numbers 'a' with 1, 'b' with 2, ..., 'z' with 26 where characters are separated by '-'.
a b c d e f g h i j k l m n o p q r s t u v w x y z
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
Input
Input will be a string in single line containing spaces and letters both uppercase and lowercase.
Output
Output should be a single line containing secret message. All characters in output should be in lower case.
Explanation
For example, if given input is "python", "p" should replaced with "16", similarly"y" with "25","t" with "20","h" with "8","o" with "15","n" with "14". So output should be "16-25-20-8-15-14".
Sample Input 1
python
Sample Output 1
16-25-20-8-15-14
Sample Input 2
Foundations
Sample Output 2
6-15-21-14-4-1-20-9-15-14-19
Does router have internet connection with network? Wired connection or Wireless connecrion?
How about modem? Does computers connect to it through internet connection , wired or wireless?
If modem or router is not available, what alternatives devices can you used? THANK YOU!
A lady behaves like a teacher in a classroom, mother or daughter in a home and
customer in a market. Here, a single person is behaving differently according to the
situations. Consider a above real-life example and which concept you will use in cpp.
Elaborate the concept.Explain in theory.
Create a Python class named BankAccount which represents a bank account with the following attributes: numAccount, name (name of the owner of the account) and balance. 1. Create the constructor (__init__ method) 2. Create a method deposit() which manages payments. 3. Create a withdrawal() method that handles withdrawals. 4. Create a display() method that displays the details of the account 5. Create an instance of the class BankAccount and call the three methods defined.
This is Compilers questions.
True/False questions:
Consider Following list of elements, Show arrangement of elements until four numbers of iterations
while applying Selection, Insertion, and Bubble Sort Algorithms.
2, 6, 1, 8, 9, 7, 10, 24
Solve the following time complexity
T(n) = ∑ ∑ 1
𝑖
𝑗=0
𝑛−1
𝑖=1
b. Write an algorithm/pseudocode for a movie rental company that wants to screen their customers from 18years and above. The system should be able to deny access to customers that appear below 18. (8pts)
c. Draw a Flowchart to illustrate the above program.