# -*- coding: utf-8 -*-
"""
Created on Fri Jul 24 09:37:44 2020
答疑: 李立宗 [email protected]
while語句
將正數,負數分組存放
"""
a=[-4,4,-56,66,77,-24,-55,-11,88,4,5,76,33,-100]
a1=[]
a2=[]
while len(a)>0:
t=a.pop()
if t>0:
a1.append(t)
else:
a2.append(t)
print("正數集合:",a1)
print("負數集合:",a2)