Answer:
<h2>Following are the java script code for the above question. </h2>
Explanation:
Program :
var percentage= prompt("Enter the percentage of the student"); // take the input from the user.
if(percentage>=90)//check condition for greator than 90.
alert("your grade is \"A\"");
else if(percentage>=80) // check condition for 80 and 89.
alert("your grade is \"B\"");
else if(percentage>=70) // check condition for 70 and 79.
alert("your grade is \"C\"");
else if(percentage>=60) // check condition for 60 and 69.
alert("your grade is \"D\"");
else // check condition for less than 60.
alert("your grade is \"F\"");
Output:
- If the user input 60, it will prints D.
- If the user inputs 59, it will prints f.
Code Explanation:
- The above code is in a javascript language, In which the first line is used to display the message and take the input from the user in the alert box.
- Then the percentage is checked by the help of in if, else if and else statement and print the grade.
- Then the grade is printed with the help of an alert box.
Answer:
A flat file database stores data in a single table structure. A relational database uses multiple table structures, cross-referencing records between tables. Tables in both organize records in rows, with each column containing a single piece of data in the record.
Answer:
Well, I would definitely advise him to buy USB hubs.
Explanation:
USB hub is a device that can give additional USB slot for the user just by consuming one single slots. In recent years, USB hubs can contain more than 9 slots with different variety, including HDMI and DVI that is required by this particular friend.
Using this device will make it easier to plug in and plug out all the devices he wants to his laptop since it all connected to one single hub.
Since he only has the budget under 100$ , Dell DA300 6-in-1 USB-C Hub could be a good option for Him.
public class ArithmeticAssignment {
public static void main(String[] args) {
Tester test = new Tester();
test.printTester();
}
}
class Tester{
Tester(){
}
void printTester(){
int i1 = 79 + 3 * (4 + 82 -68) - 7 +19;
int i2 = (179 +21 +10) / 7 + 181;
int i3 = 10389 * 56 * 11 + 2246;
System.out.println(i1);
System.out.println(i2);
System.out.println(i3);
}
}
I think this is what you wanted. I hope this helps!
Answer: 1. They can easily understand the logic behind solving any problem 2. Comments may help you to memorize your logic that you have written while writing that code.