Answer:
import java.util.Scanner;
public class Supermarket
{
public static void main (String[] args)
{
String item;
double pounds, ounces, price,
total, unit;
Scanner scn = new Scanner(System.in);
System.out.print("Please enter the name of item ");
item = scn.nextLine();
System.out.print("Please enter the price of " + "the item per pound : ");
price = scn.nextDouble();
System.out.print("Enter the weight of " + "the item in pounds and " + "ounces respectively : ");
pounds = scn.nextDouble();
ounces = scn.nextDouble();
unit = price/16;
total = price * (pounds + ounces/16);
System.out.print("The unit price of " + "the products sold is : " + unit);
System.out.print("\nThe total cost of the " + "amount purchased is : " + total);
}
}
Explanation:
- Ask the user to enter the price of the item and the weight.
- Calculate the unit and the total price.
- Display the unit and the total price.
Answer:controlling a situation by making things happen or by preparing for possible future problems
Explanation:
Answer:
a. Local user profile.
Explanation:
Local user profile is a type of user profile which is stored in the C:\Users folder and is automatically created when a user logs on to the computer for the first time and it is being stored on the local hard disk of the computer.
Generally, in Microsoft windows any change made to the local user profile is peculiar to the user and the host computer on which the change is made.
Hence, local user profiles avails several users the opportunity of sharing a single computer with their respective user settings and data.
An example of selection structure is when a group of people wanted to know the exact number of days through the use of a data set that has the daily high temperature which ranges from above 80 degrees, and as such, a programmer can use the if-end statement.
<h3>What is an if statement?</h3>
An IF statement is known to be a kind of statement that is executed due to the happening of a specific condition.
Note that IF statements must start with IF and end with the END.
Therefore, An example of selection structure is when a group of people wanted to know the exact number of days through the use of a data set that has the daily high temperature which ranges from above 80 degrees, and as such, a programmer can use the if-end statement.
Learn more about if-end statement from
brainly.com/question/18736215
#SPJ1
Answer:
C. SQL injection.
Explanation:
SQL is a relational database that is used by websites and web applications to hold data needed in the application. websites or applications with relational database like SQL are prone to SQL injection attacks.
SQL injection attacks are used to run malicious SQL statement to take control of the databases run by a website or application. With the vulnerability, an attacker can modify the content of a website's SQL database or can retrieve all data from it, after bypassing the security.
The data transmitted to the website or application from the fields in the datasheet can be manipulated or modified.