0
The point is that the values of bb
,cc
,dd
nay are being inserted into the vectors vx
,vy
,vz
.
vr=vx=vy=vz=[]
N=aa=bb=cc=dd=0
N=int(input())
for i in range(N):
aa,bb,cc,dd=map(float, input().split())
vr.append(aa)
vx.append(bb)
vy.append(cc)
vz.append(dd)
print(aa,bb,cc,dd)
print(vr[i],vx[i],vy[i],vz[i])
What should this code do? What is the input and what is the output produced?
– Woss
Do you understand that
vr
,vx
,vy
andvz
are the same list right? There are 4 different lists.– fernandosavio
Hmmmm, vlw! Bro, thanks a lot! I hadn’t thought of that.
– mdmundo
How confusing this code.
– Maury Developer
I don’t know what your endgame is with this, or who’s gonna use it for what, but gather
input("Digite quatro números separados por espaço: ")
instead of justinput()
makes life easier for anyone running this program - even if it’s just you.– jsbueno