Answer:
import java.util.Scanner;
public class Solution {
public static void main(String args[]) {
Scanner scan = new Scanner(System.in);
System.out.println("Enter your value");
int value = scan.nextInt();
greaterThanFive(value);
}
public static void greaterThanFive(int userInput){
System.out.println(userInput > 5);
}
}
Explanation:
The first line import the Scanner which is use to enable to accept user input.
The class is defined as Solution in the next line. The main method is declared in the next line which signify the beginning of the program.
Then, a scanner object is declared called scan in the next line. Then a prompt is display to the user to input a value. The user input is stored in the variable value. The value is then passed to the method greaterThanFive.
The method greaterThanFive is declared and have just one parameter, the userInput. Inside the method, we output if the userInput is greater than 5 using the logical operator (>).
Answer:
class OddNumber
{
public static void main(String args[])
{
int n = 1000; //Store 1000 in Variable n typed integer
System.out.print("Odd Numbers from 1 to 1000 are:"); // Print headline of output window
for (int i = 1; i <= n; i++) //For loop to go through each number till end
{
if (i % 2 != 0) //check if number is even or odd.Not divisible by 2 without reminder means it is odd number
{
System.out.print(i + " "); //print odd numbers
}
}
}
}
Answer:
1. Open Shortest Path First (OSPF)
2. Border Gateway Protocol (BGP)
3. Routing and Remote Access Service (RRAS)
4. Frame relay
5. Synchronous
6. Virtual
7. Committed Information Rate (CIR)
8. Integrated Services Digital Network (ISDN)
9. Asynchronous Transfer Mode (ATM)
10. Basic Rate Interface (BRI).