Answer:
- with(open("numbers.txt")) as file:
- data = file.readlines()
- runsum = 0
- largest = 0
-
- for x in data:
- if(int(x) > largest):
- largest = int(x)
- runsum += largest
-
- print(runsum)
Explanation:
The solution code is written in Python 3.
Firstly, open a filestream for numbers.txt (Line 1) and then use readlines method to get every row of data from the text files (Line 2).
Create a variable runsum to hold the running sum of number bigger than the maximum value read up to that iteration in a for loop (Line 3).
Use a for loop to traverse through the read data and then check if the current row of integer is bigger than the maximum value up to that point, set the current integer to largest variable and then add the largest to runsum (Line 6 - 9).
At last display the runsum to console terminal (Line 11).
Answer:
The following statement is False.
Explanation:
When any user or person using IAM platform of the Google Cloud that give permission to the user for the particular granular access. It provides user control by setting IAM policies of what access to which services.
That's why it not restricted to view if the user applies for the restrictive rules to that resources.
Answer:
In C++ we can assign a character to the variable by using the below statement.
ch='X';
Explanation:
The complete program for assigning a character to the variable is given as
#include<iostream>
#include <conio.h>
using namespace std;
main()
{
char ch;
ch= 'X';
cout<<"output of variable Ch ="<<ch;
getch();
}
In above program Char is the data type used for character type variables. ch= 'X' stores X in ch. Then output will shown through cout.
Answer:
SYN spoofing attacks.
Explanation:
The Spoofing attack is used to access the personal information it is distributed the viruses through infected links or file .The spoofing attacks has redistributed the traffic and the flow control in the denial-of-service attacks.
The SYN spoofing attacks is used the spoofed source in the result of giving response to packet The Spoofing attack is distributed across the Internet also it is detectable
Circular errors are caused by adding the cell name of the active cell to its own formula.