diff options
Diffstat (limited to 'progs/a708.py')
-rw-r--r-- | progs/a708.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/progs/a708.py b/progs/a708.py new file mode 100644 index 0000000..84dda65 --- /dev/null +++ b/progs/a708.py @@ -0,0 +1,3 @@ +def diff_consecutivenums(nums):
+ result = [b-a for a, b in zip(nums[:-1], nums[1:])]
+ return result
\ No newline at end of file |