From d301fbcbf24471b9699cba4d333724e984c7658f Mon Sep 17 00:00:00 2001 From: Faraz <68803375+faraz6188@users.noreply.github.com> Date: Fri, 23 Oct 2020 09:48:15 +0530 Subject: [PATCH] Update SimpleFactorial changed to include and removed some braces --- Beginner/SimpleFactorial | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/Beginner/SimpleFactorial b/Beginner/SimpleFactorial index 52c44c28..61ce3d2c 100644 --- a/Beginner/SimpleFactorial +++ b/Beginner/SimpleFactorial @@ -1,13 +1,11 @@ - +#include using namespace std; int main() { -int n, i; +int n; cin>>n; int product=1; -for(i=n; i>0; i--) -{ +for(int i=n; i>0; i--) product = product*i; -} return 0; }