A already assigned variable cannot be assigned twice You can make the variable change over to a new one or call a whole new one to assign one without a value or It might be possible to do v=n (v is variable and n is number / value)
Answer:
1. Classes and objects
2. Inheritance
3. Polymorphism
4. Data hiding/ encapsulation
5. Interfaces.
Explanation:
Classes and objects depict the major component of the OOP (object oriented programming). It explains the object like a ball in a soccer game development.
The inheritance is like the subclass of the object. Data hiding is a stage in oop where the codes or data are hidden from another users.
In the polymorphism stage, the object is given the ability to change to a sub-object, while in the interface stage a function or method signature is defined without implementing it.
Answer:
b. an e-mail
Explanation:
Based on the scenario being described within the question it can be said that the best electronic communication tool in this scenario would be an e-mail. Using e-mails you would be able to send detailed communication messages to all of the individuals that need to read that message in one e-mail. Thus allowing for fast and clear communication between all relevant parties. Both podcasts and Wiki's are used for providing information to clients, or the target audience but not for sharing info within the company.
Answer:
import java.util.*;
public class MyClass {
public static void main(String args[]) {
Scanner input = new Scanner(System.in);
System.out.print("Input a word: ");
String userinput = input.nextLine();
for(int i =0;i<userinput.length();i+=2) {
System.out.print(userinput.charAt(i));
}
}
}
Explanation:
This line prompts user for input
System.out.print("Input a word: ");
This declares a string variable named userinput and also gets input from the user
String userinput = input.nextLine();
The following iterates through every other character of userinput from the first using iteration variable i and i is incremented by 2
for(int i =0;i<userinput.length();i+=2) {
This prints characters at i-th position
System.out.print(userinput.charAt(i));