Question: Please save the program with the name 'triangle.c' Write a nested for loop that prints the following output: 1. 1 2 1 1 2 4

Please save the program with the name 'triangle.c' Write a nested for loop that prints the following output: 1. 1 2 1 1 2 4 2 1 1 2 4 8 4 2 1 1 2 4 8 16 8 4 2 1 1 2 4 8 16 32 16 8 4 2 1 1 2 4 8 16 32 64 32 16 8 4 2 1 1 2 48 16 32 64 128 64 32 16 842 1 Hint: Here is the psudocode solution: for row from 0 to 7{ pad leading blanks in a row like this for the column from 1 to 7-row: print a set of spaces print left half of row for column from 0 to row: print spaces followed by 2 raised to the power of the column print right half of row for column from row-1 to 0: print spaces followed by 2 raised to the power of the column print a new line 2. Please save the program with the name 'grade.c' Write a program that will prompt the user to input ten student scores to an array, The score value is between 0 100. The program will display the smallest and greatest of those values. It also displays the average score. Example: please input student scores one at a time. Student 1 : -10 Try again! Student 1 : 10 Student 2 : 110 Try again! Student 2: 20 Student 3 : 30 Student 4 : 40 Student 5 : 50 Student 6 : 60 Student 7 : 70 Student 8 : 80 Student 9 : 90 Student 10 : 100 *final result ***** The maximum score is 100 The minimum score is 10 The averange score is 55
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
