Q. Change the above code so that it works as stated in previous question.
Answer :-
NumLst = [2, 5, 1, 7, 3, 6, 8, 9]
SqLst = [ ]
for i in NumLst :
SqLst .append( i * 2 )
print (SqLst)
Output :-
[4, 10, 2, 14, 6, 12, 16, 18]
>>>
Answer :-
NumLst = [2, 5, 1, 7, 3, 6, 8, 9]
SqLst = [ ]
for i in NumLst :
SqLst .append( i * 2 )
print (SqLst)
Output :-
[4, 10, 2, 14, 6, 12, 16, 18]
>>>
Answer ?
ReplyDeleteThere no answer
ReplyDeletePost a Comment
You can help us by Clicking on ads. ^_^
Please do not send spam comment : )