Answer:
- \' is used to escape a single quote in a string enclosed in single quotes like;
my_string = 'this is John\'s ball'.
- \n is used to jump to a new line, Eg;
my_string = "Johns is a good boy\nbut he hates going to school."
the next set of the string after the '\n' character is displayed on the next line.
- \t is used to add a tab space to a string.
my_string = 'Jane is \thungry'
the character adds four character spaces before the word 'hungry'.
- \r adds a carriage return (or enter in keyboards) to start a new block paragraph in a string.
my_string = "Johns is a good boy\rbut he hates going to school."
Explanation:
Escape sequences in programming are used to format strings or output syntax of a program. They always begin with the backslash. Examples of escape sequence are " \' ", "\n", "\t", "\r", etc.
Add the following constants in the class definition, before the main method:
private final static float START_COST = 1.5f;
private final static float HIGH_TARIFF = 0.5f;
private final static float LOW_TARIFF = 0.25f;
private final static int FIXED_MINS = 2;
private final static int HIGH_TARIFF_MINS = 10;
Then add this to the main method you already had:
float price = START_COST;
if (x > FIXED_MINS) {
if (x <= HIGH_TARIFF_MINS) {
price += HIGH_TARIFF*(x-FIXED_MINS);
}
else {
price += HIGH_TARIFF*(HIGH_TARIFF_MINS-FIXED_MINS)
+ LOW_TARIFF*(x-HIGH_TARIFF_MINS);
}
}
System.out.printf("A %d minute call costs %.2f", x, price);
Answer: use this link :- https://www.file-extension.info/conversion/enw-to-pdf
Explanation:
Answer:
Data manipulation languages are used for the retrieval of the,insertion,deletion and modification of data.
Explanation:
Data Manipulation Languages(DML) are used to insert,delete,update,modify the data in the database.
The commands used to do these operations are as following:-
INSERT INTO :-This command is used to insert values in the database.
DELETE:-It is used to delete existing records from the table.
UPDATE:- It is used to modify the records in the table.
SELECT:- It is used to select data from database.