Answer:
import java.util.Scanner;
public class num2 {
public static void main(String[] args) {
Scanner in = new Scanner(System.in);
int total = 0;
for(int i=0; i<5; i++){
System.out.println("Enter next Int: ");
total = total+in.nextInt();
}
System.out.println(total);
}
}
Explanation:
In the code above written in Java programming language, the for loop statement for(int i=0; i<5; i++) ensures that the loop goes from 0-4 a total of five times.
At each iteration it requests a user to enter an int. The number entered is stored in the variable total which is initially assigned 0.
When the loop finishes execution, total is printed out
Answer:
import random
print("Hello! I have a random number from 1 to 100! It is your job to try and guess it!")
number = random.randint(1,101)
guess = int(input("start to guess: "))
num_guesses = 1
while guess != number:
if guess > number:
print("lower")
guess = int(input("try again: "))
num_guesses +=1
elif guess < number:
print ("higher")
guess = int(input("start to guess: "))
num_guesses +=1
print("congrats it took you", num_guesses, "tries")
Explanation:
Answer:
Compress
00eb:0000:0000:0000:d8c1:0946:0272:879
IPV6 Addres
Explanation:
Answer:
the ergonomics To prevent a laptop from being stolen, you can use a surge protector. False; To prevent laptops from being stolen, you can use a cable lock. What is a digital certificate?