From 55659e76bddef69641c10a1dd11935f47338d6e4 Mon Sep 17 00:00:00 2001 From: Russ Carroll Date: Thu, 8 Oct 2020 19:16:08 +0000 Subject: [PATCH 1/2] Add d6_roll.py file. --- d6_roll.py | 1 + 1 file changed, 1 insertion(+) create mode 100755 d6_roll.py diff --git a/d6_roll.py b/d6_roll.py new file mode 100755 index 0000000..cb30193 --- /dev/null +++ b/d6_roll.py @@ -0,0 +1 @@ +import random; print(random.randint(1,6)) From f810c28f32f995470c20b17eb5a5cec7b4fdf361 Mon Sep 17 00:00:00 2001 From: Russ Carroll Date: Thu, 8 Oct 2020 19:22:18 +0000 Subject: [PATCH 2/2] Updated with a doc string at the beginning. --- d6_roll.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/d6_roll.py b/d6_roll.py index cb30193..43a2d29 100755 --- a/d6_roll.py +++ b/d6_roll.py @@ -1 +1,2 @@ -import random; print(random.randint(1,6)) +#Generates a random number between 1 and 6 mimicking a roll of a standard 6-sided die. +import random; die_roll = random.randint(1,6))