我有这个公式:
=NETWORKDAYS(J16;K16;Helgdagar!$A$1:$A$28)-SIGN(NETWORKDAYS(J16;K16;Helgdagar!$A$1:$A$28))
如果结果是否定的,我希望结果说" 0"。我怎么能这样做?
答案 0 :(得分:0)
尝试:
=Max(NETWORKDAYS(J16;K16;Helgdagar!$A$1:$A$28)-SIGN(NETWORKDAYS(J16;K16;Helgdagar!$A$1:$A$28));0)
如果要保留负数但显示0,请使用以下自定义格式:
0;"0"
它会将任何负数屏蔽为0,但保留潜在的负值。
答案 1 :(得分:0)
也许......
import sys
def readfromconsole():
new_list = []
while True:
line = sys.stdin.readline().rstrip("\n")
if(line == 'enough'):
break
else:
new_list.append(line)
print(new_list)
return
print("Welcome")
print("please enter your input, enough to stop")
readfromconsole()