Answer:
Following are the code to this question:
list_val = input()#defining a integer variable for input value
test_grades = list(map(int, list_val.split()))#defining test_grades as a list
sum_extra = -999 #defining sum_extra that holds negative integer value
sum_extra = 0#defining sum_extra that holds value
for y in range(len(test_grades)):#defining a for loop to check range of list
if(test_grades[y] > 100):# defining if block that check list value is greater then 100
sum_extra = sum_extra + (test_grades[y] - 100)#use sum_extra variable to hold extra value and add this value
print('Sum extra:', sum_extra)#print value
Output:
101 83 107 90
Sum extra: 8
Explanation:
In the above code a, "list_val" variable is declared, that uses an input method to input the values and declared a "test_grades" variable that uses a list method to add all values in the list.
In the next step, the "sum_extra" variable is declared, which holds some values and defines a for loop to check the range of the "test_grades", and define a if block, that checks list value is greater than 100. If the condition is true, it will remove the extra value, and add it into the sum_extera variable and add its value, and at the last use, print variable to print its value.
<span>Format ribbon. the ribbon containing options for formatting fonts. One can change case, style, bold, italics, underline etc using the short cut keys in the format ribbon or using the menu options provided in the ribbon. It is common for microsoft word or excel applications.</span>
The two major SAS steps are data and proc.
SAS programming structure is based on two essential steps, Data and Proc.
1. The DATA step:
This involves collecting and uploading the essential data to the program memory. It is used to update, modify and edit the data in case of any errors once it has been added to a dataset. New datasets can be created from existing ones by updating, editing, and/or merging them. at the end of this step, SAS data sets are created.
2. The PROC step:
This step processes and analyses the data collected into datasets in the previous step. it is used to perform specific functions on the data. at the end of the proc step, a result or report is produced.
In a SAS code, each line of code should begin either with a DATA or PROC step.
<u>While the other options are incorrect because: </u>
<u />
- Analysis: analysis is done in the PROC step.
- Content: Data or content is collected in the DATA step.
- Stat: a stat function acquires the status information regarding a specific file. Functions are performed on the datasets in the PROC step.
- Run: This command is used to execute a code.
- Import: Datasets are created by importing data from other datasets and outside.
- Print: the report produced at the end of the PROC step can be printed as a hard copy.
You can learn more about SAS at
brainly.com/question/13615203
#SPJ4
Answer:
#include<iostream>
using namespace std;
//main function
int main(){
//nested for loop
for(int i=9;i>=1;i--){
for(int j=1;j<=i;j++){
cout<<j<<" "; //display
}
}
return 0;
}
Explanation:
Include the library iostream for using the input/output instruction in the c++ programming.
Create the main function and takes nested for loop. Nested for loop means, for loop inside the another for loop.
For every value of outside for loop, inside for loop execute.
we make outer for loop in decreasing format, means it start from 9 and goes to 1 and inside for loop make in increasing format, means loop start from 1 and it goes to that value which is provided by the outer loop.
and print the output for every cycle.
Lets dry run the code:
the outer loop starts from 9 and it checks the condition 9>=1, condition true. then the program moves to the inner loop which starts from 1 and goes to the 9.
first, it also checks the condition 1 <= 9, condition true and prints the number from 1 to 9.
then, i is reduced by 1. it means i become 8.
then, the above process continues from 1 to 8 and so on...
the loop process will terminate if the outer loop terminate.
Finally, we get the output.