Programming & Computer Science Answers

C++ 9913
Python 5288
Java | JSP | JSF 3611
C 1680
C# 1362
Computer Networks 989
Algorithms 652
Databases | SQL | Oracle | MS Access 641
HTML/JavaScript Web Application 588
Other 537
Visual Basic 358
Assembler 209
Software Engineering 202
AJAX | JavaScript | HTML | PHP 166
MatLAB 150
MatLAB | Mathematica | MathCAD | Maple 124
Action Script | Flash | Flex | ColdFusion 112
UNIX/Linux Programming 89
Web Development 73
Excel 36
ASP | ASP.NET 23
Delphi | Pascal 21
Perl 16
Prolog 9
Functional Programming 9
MathCAD 5
Wolfram Mathematica 4
WPF 4
Ruby | Ruby on Rails 3
NodeJS Web Application 2

Questions answered by Experts: 26 876

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

Write a program that first reads an integer for the array size,



then reads characters into the array, and displays the consonants (i.e., a character



is displayed only if it a consonant). (Hint: Read a character and store it to an array



if it is not a vowel. If the character is a vowel, discard it. After the input, the array



contains only the consonants.)

Write a program that first reads an integer for the array size, then





reads numbers into the array, counts the even numbers and the odd numbers and





displays them.

Write algorithm using pseudocode and flowchart that uses while loops to perform the




following steps:




i. Prompt the user to input two integers: firstNum and secondNum note that firstNum




must be less than secondNum.




ii. Output all odd numbers between firstNum and secondNum.




iii. Output the sum of all even numbers between firstNum and secondNum.




iv. Output the numbers and their squares between firstNum and secondNum.




v. Output the sum of the square of the odd numbers between firstNum and secondNum.




b. Redo Exercise (a) using for loops.




c. Redo Exercise (a) using do. . .while loo

Write a menu driven program that achieves the following:

  1. Takes student’s information from the user and adds such a student into Mark Sheet.
  2. Takes a student number from the user and update such a student’s information.
  3. Takes a student number from the user and delete such a student from Mark Sheet.
  4. Generate or re-generate individual student report files.
  5. Write a short report on the approach you used to solve the problem in hand.

Write a program with total change amount as an integer input, and output the change using the fewest coins, one coin type per line. The coin types are Dollars, Quarters, Dimes, Nickels, and Pennies. Use singular and plural coin names as appropriate, like 1 Penny vs. 2 Pennies. 

Ex: If the input is: 

0 

(or less than 0), the output is: 

No change 

Ex: If the input is: 

45

the output is: 

1 Quarter
2 Dimes 

Write a program whose inputs are three integers, and whose output is the smallest of the three values. 

Ex: If the input is: 

7 15 3

the output is: 

3




The population of a town A is less than the population of town B. However, the population of 

town A is growing faster than the population of town B. Write algorithm using pseudocode and 

flowchart that prompts the user to enter the population and growth rate of each town. The 

algorithm outputs after how many years the population of town A will be greater than or equal to 

the population of town B and the populations of both the towns at that time. (A sample input is: 

Population of town A = 5000, growth rate of town A = 4%, population of town B = 8000, and 

growth rate of town B =2%)


New Dictionary

Peter is making a new dictionary.He wants to arrange the words in the ascending order of their length and later arrange the ones with the same length in lexicographic order.Each word is given a serial number according to its position.Find the word according to the serial number.

Input

The first line of input is a positive integer which is the serial number.


Word Serial Number

A 1

B 2

C 3

... ...

X 24

Y 25

Z 26

AA 27

AB 28

... ...

BA 53

... ...

ZZ 702

AAA 703

Explanation

Given serial number is 42.

As the serial number is between 26 and 52, the first character of the word is A.The remaining counter of the serial number is 16 (42-26).

The second character of the word is the 16th alphabet, which is P.

So, the output should be AP.


Sample Input1

42

Sample Output1

AP


Sample input2

751

Sample output2

ABW



a. Write algorithm using pseudocode and flowchart that uses while loops to perform the 

following steps:

i. Prompt the user to input two integers: firstNum and secondNum note that firstNum 

must be less than secondNum.

ii. Output all odd numbers between firstNum and secondNum.

iii. Output the sum of all even numbers between firstNum and secondNum.

iv. Output the numbers and their squares between firstNum and secondNum.

v. Output the sum of the square of the odd numbers between firstNum and secondNum.

b. Redo Exercise (a) using for loops.

c. Redo Exercise (a) using do. . .while loops.


New Dictionary


Peter is making a new dictionary.He wants to arrange the words in the ascending order of their length and later arrange the ones with the same length in lexicographic order.Each word is given a serial number according to its position.Find the word according to the serial number.


Input

The first line of input is a positive integer which is the serial number.


Output

The output should be a single line containing the word that represents the serial number.


Explanation

Given serial number is 42.

As the serial number is between 26 and 52, the first character of the word is A.The remaining counter of the serial number is 16 (42-26).

The second character of the word is the 16th alphabet, which is P.

So, the output should be AP.


Sample Input1

42

Sample Output1

AP


Sample input2

751

Sample output2

ABW


LATEST TUTORIALS
APPROVED BY CLIENTS