Answer:
Explanation:
The following code is written in Java. It creates the Bug class with the position and direction variables. Then it creates a constructor, move method, turn method, and getPosition method. Finally, a bug object called bugsy is created in the main method, and we move it once to the right, then again to the right, and then we turn it and move it 5 times to the left, printing out the position when it is done moving. Output can be seen in the attached picture below.
class Brainly {
public static void main(String[] args) {
Bug bugsy = new Bug(10);
bugsy.move();
System.out.println("Current bug position: " + bugsy.getPosition());
bugsy.move();
System.out.println("Current bug position: " + bugsy.getPosition());
bugsy.turn();
bugsy.move();
bugsy.move();
bugsy.move();
bugsy.move();
bugsy.move();
System.out.println("Current bug position: " + bugsy.getPosition());
}
}
class Bug {
char direction = 'r';
int position = 0;
public Bug(int initialPosition) {
this.position = initialPosition;
}
public void turn() {
if (this.direction == 'r') {
this.direction = 'l';
} else {
this.direction = 'r';
}
}
public void move() {
if (this.direction == 'r') {
this.position += 1;
} else {
this.position -= 1;
}
}
public int getPosition() {
return this.position;
}
}
Answer:
c. Norms.
Explanation:
When Elena noticed her friend getting uncomfortable when she kisses him on the cheeks as a form of greeting she was violating his norms.
Norms are something that is standard or typical.
In USA there they not used to kiss on the cheeks to greet their friends there would be some other norm of greeting someone.
Answer:
The output is second half of the month, refers to both
Answer:
This Print Screen key is used to take the screenshots of all that is appearing on the screen, and this can then be pasted in paint and saved in some location of the computer.
The Home key takes the cursor from the current position to the top left, or the start of the file.
Shift: There are two shift keys. And they are used to print the character in the capital. And when the caps lock is busy it can be used to print in lower case. It is also used together with arrow keys to select a part of the text.
Tab: This key moves the cursor from the current location to the location which we know as tab stops ( and the very next one).
Pg Up: The page up is being used for scrolling up, and the distance to which limit the scrolling will take place depends upon the application you are working on.
Explanation:
Please check the answer.