[ edit ]

# ----- 指定範囲の整数の総和を求める関数の定義 -----
def sum_of_range( start, end ):
    sum = 0
    for i in range( start, end+1 ):
        sum += i
    return( sum )

SoftEng: Python/Prog/Practice/Basic/02/BP_003a/Digest (last edited 2019-10-16 14:35:42 by TadashiIijima)