subject

Write a Python program that allows the user to input a word. The program then outputs each character in the word with the corresponding position starting at 1. For example, if the user enters "Hello", the program will output: 1 H 2 e 3l 4l 5O Your program should work as follows: Gets the user to enter a string and store it in a suitable variable • Output each character along with its position in the string. The positions output should start at 1 You should use meaningful variable name(s), correct syntax and indentation in your answer. The answer grid below contains vertical lines to help you indent your code accurately, [8 marks]

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 13:50
The instruction ishl (shift left integer) exists in jvm but not in ijvm. it uses the top two values on the stack, replacing the two with a single value, the result. the sec- ond-from-top word of the stack is the operand to be shifted. its content is shifted left by a value between 0 and 31, inclusive, depending on the value of the 5 least signifi- cant bits of the top word on the stack (the other 27 bits of the top word are ignored). zeros are shifted in from the right for as many bits as the shift count. the opcode for ishl is 120 (0x78).a. what is the arithmetic operation equivalent to shifting left with a count of 2? b. extend the microcode to include this instruction as a part of ijv.
Answers: 1
question
Computers and Technology, 23.06.2019 23:40
4. what is the reason for including the following code snippet in the header file animal.h? #ifndef animal_h #define animal_h class animal { public: animal(); animal(double new_area_hunt); void birth(); void hunt(double new_area_hunt); void death(); double get_area_hunt() const; private: double area_hunt; }; #endif
Answers: 3
question
Computers and Technology, 25.06.2019 06:00
If an image has only 4 colors, how many bits are necessary to represent one pixel’s color?
Answers: 1
question
Computers and Technology, 25.06.2019 15:30
Finally, think about a way to add 1 to the score each time the ball touches the edge of the stage. see if you can add this to the project. answer quickly
Answers: 1
You know the right answer?
Write a Python program that allows the user to input a word. The program then outputs each character...
Questions
question
English, 08.12.2020 21:30
question
History, 08.12.2020 21:30
question
History, 08.12.2020 21:30
question
Mathematics, 08.12.2020 21:30
Questions on the website: 13722367