Skip to content

Commit 9dc32a4

Browse files
authored
Make README more descriptive
1 parent 05cba25 commit 9dc32a4

1 file changed

Lines changed: 37 additions & 1 deletion

File tree

README.md

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,38 @@
1-
# python-factorial
1+
# Python factorial
2+
23
A short Python program that finds the factorial of a positive integer.
4+
5+
## Setup and run
6+
7+
### Prerequisites
8+
9+
Before you can run this program, you need to [install Python](https://www.python.org/downloads/) on your system.
10+
11+
### Cloning the repository
12+
13+
To clone this repository locally, run the following command from your terminal:
14+
15+
```shell copy
16+
git clone https://github.com/new2code/python-factorial.git
17+
```
18+
19+
### Running the program
20+
21+
1. To open the repository's directory, run the following command from your terminal:
22+
23+
```shell copy
24+
cd python-factorial
25+
```
26+
27+
2. To calculate the factorial of a specific number, in `factorial_finder.py`, update the value of `number`.
28+
3. To run the program on Mac or Linux, run the following command in your terminal:
29+
30+
```shell copy
31+
python factorial.py
32+
```
33+
34+
Otherwise, to run the program on Windows, run the following command from the command line:
35+
36+
```shell copy
37+
py factorial.py
38+
```

0 commit comments

Comments
 (0)