Courses
Courses
Code Compiler
Code Compiler
Discuss
Pricing
Teams
Log in
Register
Menu
Q&A Discussions
Search
Search
Ask a question
Ask a question
what happens for return 1;
c++
1 Vote
3 Answers
17th Jun 2016, 12:29 AM
Andrew
int i= 1; printf("%d %d %d\n", i++,i++,i);
c
1 Vote
5 Answers
14th Jun 2020, 8:58 AM
Rahul Kumar
Error en let abe = 1;
ecmascript
1 Vote
1 Answer
21st Sep 2020, 1:19 AM
Enrique Gonzalez
for( i = 1; i < n; i++)
no
0 Votes
4 Answers
5th Dec 2023, 4:38 PM
FAIQi
let total = 0, count = 1; while (count <= 10) { total += count; count += 1; } console.log(total);
javascript
1 Vote
3 Answers
8th Nov 2020, 6:51 AM
Kayode Kolade Christopher
what if we end program with return 1;
c++
1 Vote
3 Answers
2nd Sep 2016, 4:05 PM
Ankit Ojha
What happen if we se return 1; in place of return 0;
0
necessary
return
why
5 Votes
2 Answers
16th May 2019, 4:43 PM
SK@123
function fib(num){ if(num<=2) return 1; return fib(num-1)+fib(num-2); } document.write(fib(6));
functions
If
0 Votes
1 Answer
23rd Jun 2017, 1:19 AM
islam moheb
n = 1; while (n < 10) { printf("%d ", n++); }
c++
1 Vote
2 Answers
5th Dec 2021, 8:48 AM
Christine Jane Dulay
Qe pasa si pones return 1; al final del main
c++
0 Votes
2 Answers
9th Mar 2017, 6:13 PM
dante inferno
if we use return 1; instead return 0; what happens?
c++
0 Votes
2 Answers
11th Aug 2016, 5:05 PM
Padam Singh
why is the answer not 1; for the description belonw
arrays
multidimensional
1 Vote
1 Answer
22nd Sep 2016, 2:46 PM
Kyei Moses
int b = 1; b = b++; Why is b's final value 1 and not 2?
c++
increment
operators
6 Votes
8 Answers
9th Jan 2017, 2:00 PM
Eligijus Silkartas
int num = 1; while(num<=20){ if (num % 3 == 0){ cout<<num<<endl; } num+=1; }
while
0 Votes
4 Answers
7th Aug 2022, 8:21 AM
Erkaboev Ilhom Isomjonovich
int x = 1; while(x > 0) { System.out.println(x); if(x == 4) { break; } x++; }
break
java
loop
while
2 Votes
4 Answers
5th Nov 2019, 3:23 AM
Minhaj Haider
#include <iostream> using namespace std; int main() { int x=2; cout <<(x-++--x); return 1; }
c++
data-types
0 Votes
4 Answers
25th Sep 2016, 12:40 PM
Sourabh Goyal
What is the difference between return 0; return 1; return -1; in C programming Language ?
c
c++
developer
programmer
1 Vote
2 Answers
24th Sep 2018, 3:08 PM
Kumar Atul Jaiswal
x -= 1; // 2 x /= 2; // 3 x %= 2; // 1
operators
0 Votes
2 Answers
16th Nov 2018, 6:22 PM
Esra Gül Anlar
What is the difference between return 0 ; and return 1; in c++ i can hardly underrated??
totallycofused
1 Vote
3 Answers
27th Sep 2017, 8:27 AM
Prateek Gupta
function x(){ for(var i = 1; i<=5; i++) { setTimeout(function (){ console.log(i); }, i * 1000); }
javascript
0 Votes
3 Answers
8th Dec 2020, 6:21 AM
harsh tiwari
// Button creation starts... let countjumps = 0; function count() { countjumps += 1; console.log(countjumps )
f
1 Vote
1 Answer
26th Aug 2022, 9:33 PM
January Martine
int num = 1; int number; while (num <= 5) { cin >> number; num++; }
simple
0 Votes
2 Answers
22nd Jun 2018, 9:28 AM
Superman Batman
What difference does it makw when the statement return 1; is used instead of return 0; ?
c++
return
0 Votes
2 Answers
3rd Jan 2020, 6:01 PM
Shailaja
public class Program { public static void main(String[] args) { } { int a = 1; while (a<=5)
tes
1 Vote
4 Answers
18th Oct 2017, 12:04 PM
Agni Rosadi
int func(int num) { int count = 0; while(num) { count++; num >>= 1; } return(count) ; }For func(435) the value returned is
c#
c++
10 Votes
4 Answers
27th Mar 2020, 5:11 AM
Raj Kalash Tiwari
What's the difference between typing in return 0; or return 1; at the end of a program?
c++
0 Votes
3 Answers
3rd Oct 2016, 9:24 PM
Shyam
for(int i = 1; i <= 5; i++) { System.out.print (i + " "); int k = 6; int sum =
code
1 Vote
4 Answers
10th Mar 2021, 7:10 AM
Monir Hossen
Write in C ++ the while functionally equivalent to the following structure for: for (i = 1; i ≤ N; i ++)
c++
for
help
while
0 Votes
5 Answers
2nd Dec 2019, 8:34 PM
panik 007
int num = 2; int x = 3; if(num >= 2) { if(x > 4) { num = 3; } else { num = 4; } } else {x = 1; }
c++
if
1 Vote
11 Answers
26th Nov 2022, 10:38 AM
Sourabh Jaiswal
How to explain ds. int x = 1; int y, result; y = x; x++; result = y + x; result += x;
int
1 Vote
3 Answers
8th Oct 2019, 1:03 AM
Arvien Albios San Miguel
int main () { for (int x = 1; x <= 10; x++) { cout << 1 + (rand() % 6) << endl; } }
rand
0 Votes
6 Answers
17th May 2020, 9:29 AM
Salini Selvam
data= { 'red' :1, 'blue' :2, 'green' :3} def makedict(** kwargs): return kwarge data = makedict( red = 1; blue =2; green =3;)
python
0 Votes
3 Answers
5th Aug 2020, 5:07 PM
Starcodelab
#include <iostream> using namespace std; int main() { int num = 1; while (num < 7) { cout << "Number: " << num
sa
0 Votes
3 Answers
23rd May 2019, 5:22 AM
alif sadam
#include <iostream> using namespace std; int main() { int num = 1; int number; int total = 0; while (num <= 5)
loops
-1 Vote
2 Answers
25th Oct 2020, 1:43 PM
Sada
in the following why the code num=num+1;can't be applied just after while loop in the beginning of curly braces? #include <iostream> using namespace std; int main() { int num = 1; while (num < 6) { cout << "Number: " << num << endl; num = num + 1; } return 0; }
c++
loops
0 Votes
7 Answers
22nd Sep 2016, 2:48 PM
Prabhat Chandra Dwivedi
bonjour à tous voilà je suis boquée au niveau de l'exercice suivant : int fact (int x) { if (x == 1) { 1; } else {
c++
recursion
0 Votes
10 Answers
26th Nov 2018, 1:18 PM
Séverine MOUNIER
what if we put return 1 in main function eg int main () { • • • • • • • • return 1; }
c++
1 Vote
6 Answers
21st Jun 2016, 8:53 AM
Tushar Chetan
I tried this code : int num = 1; int number; while (num <= 5) { cin >> number; num++; }. But it showed no output
loops
0 Votes
7 Answers
20th Jul 2018, 3:44 PM
Abhinav Anand
what if at the end of the program I write return 1; instead of return 0; what would happen to my program after compilation
c++
classes
1 Vote
3 Answers
30th Mar 2017, 9:27 AM
Timothy Achibu
#include <iostream> using namespace std; int main() { int num = 1; int number; int total = 0; while (num <= 5)
c++
-2 Votes
2 Answers
6th Feb 2021, 11:17 AM
Human
In Java, is there a way to create variable labels using another variable in a for loop:for(int x= 1; x < 3; x++){int y_x = 0;}
begginer
java
loop
0 Votes
3 Answers
21st Dec 2018, 3:06 PM
Marcelo
Someone please explain me the following statement for bubble sort 👉 for ( d = 0 ; d < n - c - 1; d++ )
c
cprogamming
1 Vote
2 Answers
28th May 2018, 11:42 AM
Satyam Kirati Namnu
#include <iostream> using namespace std; int main() { int num = 1; int number; int total = 0; while (num <= 5)
variables
0 Votes
2 Answers
4th Mar 2018, 1:36 PM
Rahul Nath
#include <iostream. #include <cstdlib> using namespace std; int main () { srand(98); for (int x = 1; x <= 10; x++) {
c++
rand
0 Votes
2 Answers
14th Jan 2017, 6:42 PM
gyana nayak
int num = 1; int number; int total = 0; while (num <= 5) { cin >> number; total += number; num++; } cout << total << endl;
c++
loops
0 Votes
8 Answers
3rd Dec 2017, 3:31 PM
Mitra
What will be the content of y and z after executing the code given below: int y=10, z=2; for (int x = 1; x <= 10; x=x+2)
javascript
0 Votes
3 Answers
2nd Aug 2020, 6:20 AM
Biswajit Sarkar
If2. Given the whole number. If it is positive, then add to it 1; in the opposite case the deduction from it .
java
-4 Votes
2 Answers
10th Feb 2021, 11:20 AM
Айнура Ишантаева
Incorrectly using functions inside loops.
<=
=
1;
10;
for(var
i
i++)
1 Vote
1 Answer
12th Jun 2018, 10:36 AM
Carlewis
how the answer become 15... any one can please explane in easy way. regards #include <iostream> using namespace std; int main() { int a = 2; int b= 1; cout<<(++a/b++)*5;
c++
1 Vote
4 Answers
31st Oct 2016, 10:24 AM
zbwafi
int num = 1; int number; int total = 0; while (num <= 5) { cin >> number; total += number; num++; } cout << tota
c++
loops
0 Votes
2 Answers
2nd Dec 2017, 7:27 PM
Mitra
Ask a question
Ask a question
Ask a question
Ask a question
< Previous
1
2
Next >
Hot today
[RESULTS] June Coding Challenge: Code for the Planet 🌍💻
22 Votes
what is the easiest language
0 Votes
Android app development :how do I start
1 Votes
Fix the following code
1 Votes
Restart Lesson
0 Votes
Code help
0 Votes
Is it possible to learn Website Development in Just 2 months and become Pro in it ?
0 Votes
Account Ban
0 Votes
What is lamba function
0 Votes
The if statement front and beginners
1 Votes