• Cursos
  • Compilador de Código
  • Discutir
  • Preços
  • Teams
Menu
0

i dont get it

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

c++recursionreturn
12th Nov 2018, 12:28 PM
prod.rai
prod.rai - avatar
1 Resposta
+ 2
Have you already studied functions?
12th Nov 2018, 12:54 PM
HonFu
HonFu - avatar

Costuma ter perguntas como essa?

Aprenda de maneira mais eficiente, de graça:

  • Introdução ao Python

    7.1M de alunos

  • Introdução ao Java

    4.7M de alunos

  • Introdução ao C

    1.5M alunos

  • Introdução ao HTML

    7.5M alunos

Ver todos os cursos
Quente hoje
I've a HTML code question
1 Votes
How my gradient is so mess I code in vscode and copied here to ask some questions please help me with this one too
0 Votes
C++
1 Votes
Offline AI Model with Fast Voice Chat
2 Votes
Please tell me about methods
1 Votes
HELP ME LEARN
0 Votes
Appointment Booking website
0 Votes
Does anyone know how to go to another "page" on the same page using the HTML button tag?
2 Votes
Mentors
1 Votes
Sololearn coders should sharpen their knowledge. What should be the output? Sololearn says it's 20. Do you agree with them?
0 Votes