Questions: 11 448

Answers by our Experts: 10 707

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Search & Filtering

write a program using delphi to calculate and store the average obtained by 5 students and print the student that made the highest mark


Objective:

Write a program that uses a structure named Student to store the following information about a student:

• Student ID

• Student Name

• Major

• Year Passed

The program should create two Student variables, store values in their members, and pass each one, in turn, to a function that displays the information about the student in a clearlv formatted

manner.


please find the question on below link:



https://drive.google.com/file/d/17pfgTzAo5QxJ0K511KVR59WrywFI6iyH/view?usp=sharing

The following finite state machine (FSM):


https://drive.google.com/file/d/1WWQJipBtYXaTGfQAFbyH166I7RX5TSCy/view?usp=sharing


generates the regular language, L = {anbm | a >= 1 and m >= 2}.

Implement the above FSM as a C++ function,


int is_abb(char * str )

{

// C++ code here

}


that returns a 1 if the given string, str, is in L and returns a 0 if str is not in L.

Assume the existence of a C++ function, int str_len(char * str), which returns the length

of the given string, str.


The following C++ program segment computes C = A * B, where A is an “m” by “n”

matrix, B is an “n” by “r” matrix and C is an “m” by “r” matrix.


for (long int i = 0; i < m; i++)

for (long int j = 0; j < r; j++)

{

long double Sum = 0;

for (long int k = 0; k < n; k++)

Sum = Sum + A[i][k] * B[k][j];

C[i][j] = Sum;

}



i) How many times does the code iterate in computing Sum?

ii) How many times does the code iterate in computing the j column of C, i.e. C[i][j] for a fixed i and j = 1, 2, 3, ..., r?

iii) How many times does the code iterate in computing the complete matrix C?


Make a C++ program that will print this output using while loop.

1

16

49

100

169



Write a code (or pseudo-code) for summing the first N odd numbers.

An academic department of Information School wants to generate students report for TEN final year students which will be graduated soon. A name list of TEN students and their FOUR scores are stored in arrays. Write a complete C++ program to do the following:

a. Create 5 parallel arrays to store the:

i. TEN students name called studentName

ii. TEN scores for subject CS402 called cs402

iii. TEN scores for subject CS315 called cs315

iv. TEN scores for subject CS607 called cs607

v. TEN scores for subject CS558 called cs558

b. Read input into the arrays and display them.

c. After processing all the information, the program should:

i. Calculate the average marks for each student

ii. Determine how many students are graduated with first class degree, with average score more than 80%.

iii. Display best student with highest score of each subject iv. Display best student with the highest average score to be awarded with chancellor award


create a C++ program using Microsoft Visual Studio to do the following tasks:



Prompt the user for the salary per year and calculate a Christmas bonus based on the number of years worked as follow. Between 1 to 5 years 1% of salary, and more than five years 2% of salary. Any other values should be considered as an error message.




Make a C++ program that will print this output:

1

16

49

100

169


LATEST TUTORIALS
APPROVED BY CLIENTS