Answer:
Code is in the attached screenshot.
Explanation:
Assumed it was written in Java based on your other question asked.
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));
Answer:
A. dict = {‘Name’: ‘Matthew’, ‘Age’: 14, ‘School’: ‘ABC School’}
Explanation:
Since <em>python does not use type when declaring a variable</em>, you must make sure you make your variables correctly or else it won't compile correctly. Lists use braces[]; Strings use quotes, "" or ''; Integers are just declared with a number(s); Dictionaries use brackets{} and inside are <u>attributes of something</u>. For instance, you can use dictionaries to describe ages, {'"Bryan": 6, "Alex": 13, etc.} <u>Sort of like a json file</u>. Dictionaries also tend to use <u>uppercase letters</u> when describing something. The only answer that has all the attributes correct is A. dict = {‘Name’: ‘Matthew’, ‘Age’: 14, ‘School’: ‘ABC School’}
hope i helped :D
Amelia wants to create a website using the Python computer language to code her site. She will also use CodeSkulptor3 is an example of browser-based code editor. The correct option is A.
<h3>What is python?</h3>
Python is a programming language generally used to make websites and software. Automated tasks and data analysis are also carried out using python.
CodeSkulptor3 is also a browser-based Python interpreter. It has implemented a subset of Python 3.
Thus, CodeSkulptor3 is an example of browser-based code editor. The correct option is A.
Learn more about python.
brainly.com/question/19045688
#SPJ1