100% found this document useful (1 vote)
2K views2 pages

Hackerearth Small Factorials Solutions

This document provides instructions for solving practice problems on a solution guide. It describes selecting a problem from the list, choosing a language, writing code in the editor, compiling and testing it on sample cases, and submitting it for judging. It then introduces the Small Factorials problem and gives its input/output format before listing solutions in various languages.

Uploaded by

Sarath Kumar
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
2K views2 pages

Hackerearth Small Factorials Solutions

This document provides instructions for solving practice problems on a solution guide. It describes selecting a problem from the list, choosing a language, writing code in the editor, compiling and testing it on sample cases, and submitting it for judging. It then introduces the Small Factorials problem and gives its input/output format before listing solutions in various languages.

Uploaded by

Sarath Kumar
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
  • Solution Guide
  • Programming Languages List

Solution Guide

You can see the practice problems list and select a problem from there. Then, you need to
select the langauge from tabs and write your code in the editor. You can compile and test
your code on sample testcases by clicking on 'Compile & Test'. You can submit your code
for judge by clicking on 'Submit'. You can refer to Judge Environment for further details.
We will describe solutions for Small Factorials in different languages for successful
submission.
Small Factorials
You are asked to calculate factorials of some small positive integers.
Input
An integer T, denoting the number of testcases, followed by T lines, each containing a
single integer N.
Output
For each integer N given at input, output a single line the value of N!
Input Constraint
1 <= T <= 100
1 <= N <= 100
Solutions in different languages for Small Factorials are written below.

C++

Clojure

C#

Haskell

Java

Javascript

Objective-C

Perl

PHP

Python

Ruby

Solution Guide
You can see the practice problems list  (http://www.hackerearth.com/problems/)and select a problem from there.

Perl (http://www.hackerearth.com/docs/solution-guide/#perl)

PHP (http://www.hackerearth.com/docs/solution-guide/#php)

P

You might also like