1
Guess the Language: #9 (programming.dev)
submitted 10 months ago* (last edited 10 months ago) by Ategon@programming.dev to c/trivia@programming.dev
import std.stdio;

void main()
{
    writeln("Enter a number:");
    int input;
    readf("%d", &input);
    writeln("Factorial:", factorial(input));
}

int factorial(int n)
{
    if (n <= 1)
        return 1;
    return n * factorial(n - 1);
}

Options: Vala, Crystal, D, Nim

Use the following link to guess an answer, answer + results posted in 12 hours. (If you say the answer in the replies please put it in spoiler tags)

https://strawpoll.com/Qrgebk7PKZp

no comments (yet)
sorted by: hot top controversial new old
there doesn't seem to be anything here
this post was submitted on 16 Aug 2023
1 points (100.0% liked)

Trivia

1 readers
0 users here now

A place to quiz others with trivia questions related to the instance!

Please keep questions on the topic of trivia. If you have a question for how to do something please post it in a community relevant to what youre doing or !no_stupid_questions@programming.dev

Guidelines

Credits

Logo base by Delapouite under CC BY 3.0 with modifications to add a gradient

founded 11 months ago
MODERATORS