1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
mariarad [96]
3 years ago
8

Given N lines of input, print the 3rd character from each line as a new line of output. It is guaranteed that each of the n line

s of input will have a 3rd character.
Input Format
A text file containing N lines of ASCII C characters.
Constraints 1 Output Format
For each line of input, print its 3rd character on a new line for a total of N lines of output.
Sample Input
Hello
World
how are you
Sample Output
Explanation of what to submit Submit your code and output in a word document. Also, submit the actual script in a separate.txt file
-----------------------------------------------------------------------------------------------------------------------------------------
Task
You are given a file with four space separated columns containing the scores of students in three subjects. The first column contains a single character (A-2), the student identifier. The next three columns have three numbers each. The numbers are between 0 and 100, both inclusive. These numbers denote the scores of the students in English, Mathematics, and Science, respectively.
Your task is to identify those lines that do not contain all three scores for students.
Input Format
There will be no more than 10 rows of data. Each line will be in the following format: [Identifier][English Score][Math Score][Science Score]
Output Format
For each student, if one or more of the three scores is missing, display:
Not all scores are available for [Identifier]
Sample Input
A 25 27 50
B 35 75
C 75 78
D 99 88 76
Sample Output
Not all scores are available for B
Not all scores are available for C
Explanation
Only scores have been provided for student B and student C.
Computers and Technology
1 answer:
Juliette [100K]3 years ago
4 0

Answer:

lines = input("enter the lines of strings: ")

line_list = lines.splitlines()

with open("third_characters.txt", "w+") as file:

   for line in line_list:

       file.write(line[2])

       file.write("\n")

Explanation:

The python module gets the input of string values from the user and splits it into a list of strings. The third character on each string item is retrieved and saved in a document file named 'third_characters.txt' with each character on a single line.

You might be interested in
What kind of service is typically not offered by hosting service​
Finger [1]

Answer:

I think the answer is Dynamic DNS

Explanation:

7 0
3 years ago
Default tab stops are set in Word every _______ inch. <br> A. ½<br> B. 1<br> C. ¼<br> D. ¾
Amanda [17]
In order to help the student expand his/her knowledge I will help answer the question. This in hope that the student will get a piece of knowledge that will help him/her through his/her homework or future tests.

Default tab stops are set every one half inch across a page. This is a default measure that Microsoft established. The correct answer is letter

A. 1/2

I hope it helps, Regards.     <span> </span>
4 0
3 years ago
Two technicians are discussing engine valve timing. Technician A says that the optimum valve timing is found through experimenta
nordsb [41]
The answer is B. A only. The optimum valve timing is found through experimentation using an engine dynamometer. The timing of the opening and closing of the valves is called valve timing. So the use of dynamometer measures the power output of a machine that is why it can measure the optimum valve timing.
7 0
3 years ago
Read 2 more answers
Please solve this,this is a scratch 2.0 question<br><br>The _______ shows the output of a script ?​
rusak2 [61]

Answer:

Console

Explanation:

Not sure exactly what scratch 2.0 is but the console is a separate window that shows the script's outputs and in some cases collect inputs, show error messages or display other info depending on what compiler you used

7 0
3 years ago
This algorithm works by selecting the smallest unsorted item in the list and then swapping it with the item in the next position
Juliette [100K]

Answer:

a) Bubble sort

Explanation:

Bubble sort is a type of sorting algorithm that swaps small value with a bigger value over a number of rounds called pass.

5 0
3 years ago
Other questions:
  • What is the danger in judging someone according to his or her social networking profile
    12·1 answer
  • Use this illustration to answer the question.
    15·1 answer
  • Ann, a user, reports that she is no longer able to access any network resources. Upon further investigation, a technician notice
    8·1 answer
  • Who is the publisher of the book Vertebrates?
    7·1 answer
  • Technologies that function within the established system are called
    12·1 answer
  • Write a method called makeStars. The method receives an int parameter that is guaranteed not to be negative. The method returns
    14·1 answer
  • 16. A
    15·1 answer
  • 2.<br> Solve each equation.<br> a)<br> 3n - 8 = 2n + 2<br> b)<br> 4n + 75 = 5n + 50
    14·1 answer
  • Function of Napier bone any five​
    11·2 answers
  • _______ are useful when you want the user to select one choice from several possible choices. Radio buttons Check boxes Buttons
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!