Home
Q&A
Education
Technology
Credit
General
Health
Insurance
Questions
Ask a Question
What will be the output of print str[2:5] if str=’hello world!?
Home
Education
What will be the output of print str[2:5] if...
asked
Dec 25, 2021
in
Education
by
JackTerrance
What will be the output of print str[2:5] if str=’hello world!? Select the correct answer from above options
computer-science-interview-questions
computer-science-questions
1
Answer
0
votes
answered
Dec 25, 2021
by
JackTerrance
Best answer
Explanation: It will print characters starting from 3rd to 5th. Output would be llo. … It will print characters starting from 3rd character. hope it is helpful for u
Related questions
0
votes
Q: What is the output of print str[2:5] if str = 'Hello World!'?
What is the output of print str[2:5] if str = 'Hello World!'?...
asked
Nov 23, 2020
in
Technology
by
JackTerrance
interview-question-answer
technology-questions-answers
0
votes
Q: What is the output of print str[2:] if str = 'Hello World!'?
What is the output of print str[2:] if str = 'Hello World!'?...
asked
Nov 23, 2020
in
Technology
by
JackTerrance
interview-question-answer
technology-questions-answers
0
votes
Q: What is the output of print str + "TEST" if str = 'Hello World!'?
What is the output of print str + "TEST" if str = 'Hello World!'?...
asked
Nov 23, 2020
in
Technology
by
JackTerrance
interview-question-answer
technology-questions-answers
0
votes
Q: What is the output of print str[0] if str = 'Hello World!'?
What is the output of print str[0] if str = 'Hello World!'?...
asked
Nov 23, 2020
in
Technology
by
JackTerrance
interview-question-answer
technology-questions-answers
0
votes
Q: What is the output of print str if str = 'Hello World!'?
What is the output of print str if str = 'Hello World!'?...
asked
Nov 23, 2020
in
Technology
by
JackTerrance
interview-question-answer
technology-questions-answers
0
votes
Q: .1. Find the output of the following programs.(a) 10 LET AS = “HELLO”20 LET BS = “FRIENDS”30 PRINT AS:BS
. 1. Find the output of the following programs. (a) 10 LET AS = “HELLO” 20 LET BS = “FRIENDS” 30 PRINT AS:BS 40 END Select the correct answer from above options...
asked
Nov 29, 2021
in
Education
by
JackTerrance
computer-science-interview-questions
computer-science-questions
0
votes
Q: Consider a list2 with values 70,60,50. What will be the output statements considering that the above objecthas been created already.a. print (list2*2)
Consider a list2 with values 70,60,50. What will be the output statements considering that the above object has ... print(list2*3) Select the correct answer from above options...
asked
Dec 29, 2021
in
Education
by
JackTerrance
computer-science-interview-questions
computer-science-questions
0
votes
Q: What will be the output of the following Python code? class tester: def __init__(self, id): self.id = str(id) id="224" >>>temp = tester(12) >>>print(temp.id)
What will be the output of the following Python code? class tester: def __init__(self, id): self.id = str(id) id="224" >>>temp ... >>>print(temp.id) a) 12 b) 224 c) None d) Error...
asked
Jan 2, 2023
in
Technology
by
JackTerrance
python-questions-answers
0
votes
Q: What will be the output of the following Python code? class tester: def __init__(self, id): self.id = str(id) id="224" >>>temp = tester(12) >>>print(temp.id)
What will be the output of the following Python code? class tester: def __init__(self, id): self.id = str(id) id="224" >>>temp ... >>>print(temp.id) a) 12 b) 224 c) None d) Error...
asked
Jan 2, 2023
in
Technology
by
JackTerrance
python-question-answers
0
votes
Q: following PythonWrite the output for theCodes iA : 41:100, 2:200, 3: 300, 4:400,5:5003Print A items (Print A Keys ()
following Python Write the output for the Codes i A : 41:100, 2:200, 3: 300, 4:400,5:5003 Print A items ( ... Keys () Print A values ) Select the correct answer from above options...
asked
Dec 21, 2021
in
Education
by
JackTerrance
computer-science-interview-questions
computer-science-questions
0
votes
Q: In Java,what will be the output of the following code and how?double x=2.9,y=2.5;(SOP is abbreviated form of System.out.println)SOP(Math.min(Math.floor(x),y));SOP(Math.max(Math.ceil(x),y));
In Java, what will be the output of the following code and how? double x=2.9,y=2.5; (SOP is abbreviated form ... x),y)); Explain how Select the correct answer from above options...
asked
Nov 28, 2021
in
Education
by
JackTerrance
computer-science-interview-questions
computer-science-questions
0
votes
Q: >>> list(range(0, -9,-1)) will print[-1, -2, -3, -4,-5, -6, -7, -8)[0,-1, -2, -3, -4,-5, -6, -7, -8][0,-1, -2, -3, -4, -5, -6, -7, -8,-9)
>>> list(range(0, -9,-1)) will print [-1, -2, -3, -4,-5, -6, -7, -8) [0,-1, -2, -3, -4,-5, -6, -7, -8 ... [0,-1, -2, -3, -4,-5, -6, -7] Select the correct answer from above options...
asked
Dec 28, 2021
in
Education
by
JackTerrance
computer-science-interview-questions
computer-science-questions
0
votes
Q: What would be the output of the following program segments? Give reasons to justify your answer.i) System.out.print(“Sum =”+6 + 2);ii) System.out.print(“Sum = ”+ ‘B’+ ‘2’);iii) System.out.print(“Sum = ”+ 6 + ‘B’);iv) System.out.print(“Sum = ”+ (‘B’ + ‘a’));
What would be the output of the following program segments? Give reasons to justify your answer. i) System.out.print( Sum ... + a ); Select the correct answer from above options...
asked
Nov 27, 2021
in
Education
by
JackTerrance
computer-science-interview-questions
computer-science-questions
0
votes
Q: Simran write a code print: (“hello friends”)but when she executed there comes an error what was the error and why did it occur
Simran write a code print: (“hello friends”)but when she executed there comes an error what was the error and why did it occur Select the correct answer from above options...
asked
Dec 23, 2021
in
Education
by
JackTerrance
computer-science-interview-questions
computer-science-questions
0
votes
Q: what will be the output of following python code print(‘ab12’.isalnum())
what will be the output of following python code print(‘ab12’.isalnum()) Select the correct answer from above options...
asked
Dec 24, 2021
in
Education
by
JackTerrance
computer-science-interview-questions
computer-science-questions
...