0 like 0 dislike

Question 8: Please a write a program that receives 2 integer numbers, then outputs numbers between those inputs. If the inputs are equal, write the input number instead.

*No space between the output numbers*

Input1

1 5

Output 1

12345

 

Input2

-3 3

Output2

-3-2-10123

 

Input3

5 5

Output3

5

 

[Exam] asked in Final examination by (5.9k points)
Available when: Unlimited - Due to: 2018-01-17 16:30

edited by | 46 views

30 Answers

0 like 0 dislike
Hidden content!
#include * * ****** **
#include * * *** ** **

int main(int argc, char *argv[])
{
* ** * * *** ** *** a,b,c;
* * ** *** *** *** *** ******** **** &a);
* **** ** ** ****** * * ** * &b);
*** * * ** * * **** * * a<=b; a++){
* * * ** * * * **** * **** ***** ***** *** * ****** ***** **** * ** ** ** * **** *
** * *** ** ** * *
** *** * ** ***** *** ** *** **
* * * ** * ** *** *** **** * * *** * ** *  
* ** ** ** ** * **** **** * 0;
}
* * ***** **
100/100 answered by (252 points)
0 0
Case 0: Correct output
Case 1: Correct output
Case 2: Correct output
Case 3: Correct output
0 like 0 dislike
Hidden content!
#include <stdio.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
    int a,b;
*** * * ** * **** * * ** ** **** * * * , &a, &b);
    while(a<=b) {
* * * * * *** * * * ** ***** **** ** ** **** * ** **** **** * * * * * * ** * * * ** **** * ** *** *** ** * * ** ,a);
**** ** ** ***** ** * **** ** * ** * * *** * ** * * * * * * * * ** ** * ** * * ****
* * ** * ****** *** **** * ** ** ********* * ** ** *** ** * ** * * * **** * ******* * * * *
* * * ** ** ** * * *** ** ** * *** *** ** * * **** * ** *** * * ***** * ***** *
* * *** * *** * * **** * ********* * * ** *** * * * ** ****** *** * * *** ** *** *** * *** ***
* * * ** ******* * ** * * ** **** * *** * ** * * ** ** * * * ** *** * *** * ** ** *
*** ** *** ** ** * * * *** * ** ***
    return 0;
} ** ** ** * * *** **** ** * ** * * * *** ** * * * * * * * *** * ***** *** ** * ******
100/100 answered by (246 points)
0 0
Case 0: Correct output
Case 1: Correct output
Case 2: Correct output
Case 3: Correct output
0 like 0 dislike
Hidden content!
#include <stdio.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
  int a,b;
** * * *** * *** * ** * * * * * *
  while(a<=b){
* *** ** * * ** ** *** ** ******* * **** * * ***** ***** * **** * * **** ** *** ***
* ** *** * * * ** * * * ** **** *** * *** * * **** * * * *** ** * ** * ****
* * * * * * ** ** * ** *** ** * ** ** *** *** * ** **** ** * * * ** ** * ***
* * * ** * * * * * ** * *** ** ** * * ** ** * * * ** ** ** ** * * * *
* * * *** * ** *** ** *** ** * * *** * *** ** * * ***** * ***** * ** * * **
* * ** ** **** * *** * *** ** **** **** ** * *** * *** **** ** ***** * **
* * * * **** ** ** * ** * * ** *  
  return 0;
}
100/100 answered by (273 points)
edited by
0 0
Case 0: Wrong output
Case 1: Wrong output
Case 2: Wrong output
Case 3: Wrong output
0 0
Case 0: Correct output
Case 1: Correct output
Case 2: Correct output
Case 3: Correct output
0 like 0 dislike
Hidden content!
#include <stdio.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
    int a,b;
* ** * * * * ** * * * ** * * * * &a, &b);
****** * * **** * ** ** *** *** * {
** *** *** * ** ** *** ******* ** * * * * * * * * * * *** ** **** **** * * * printf("%d" ,a);
* **** *** ** * * * *** *** * * ***** * **** ** * * * *** * * ** * ***** * ** * ****** * **
* * * *** **** *** * * * **** ** * * * *** * ** **** ** ** **** * *
** * ** ** * *** ** * * * ** ** ** **** ** * ***** ** ** * ** *** ****** * **** **** * *
*** *** * * * *** * * * * ** * ** ******* ** * * * *** * ** ****** * * ** *********** * **** * ,a);
* * * ** * * ** * *** *** **
*** *** * ** ** * ** * ****** *** **** ** **
    
    
** * * * * *** * ** 0;
}   
* * * ** * * * ** * *** ******** ** * * * * * ** ***** ** * * ** * * * **** * *** ** ** ** * *** ** *** * * * * * *** ** ** **** ** * * ** * * * * **
answered by (246 points)
0 0
prog.c: In function 'main':
prog.c:9:14: error: stray '\302' in program
              \xc2\[email protected] printf("%d" ,a);
              ^
prog.c:9:15: error: stray '\241' in program
              \xc2\[email protected] printf("%d" ,a);
               ^
prog.c:9:16: error: stray '@' in program
              \xc2\[email protected] printf("%d" ,a);
                ^
0 like 0 dislike
Hidden content!
#include <stdio.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
  int a,b;
** * * * ** * ** *** * ** ** ** * * *** *** * *
  while(a<=b){
* * * * ***** ***** * ** ** * * * * * ** * * * *** *** * *** *** * * * ** * *** *
** *** * ** * * *** ** * *** * ** ** ** ***** ** * * ***** * ** *
**** ** ****** * * ** **** ** ** * * * * *** ** *** *** * ** ** **** *
* *** ** ****** * * * *** * * ** * **** * *** ** ***** * ******* **** * *****
*** * * * * * **** ****** * **** **** *** ************** *** * ** ** *** ** * * * * * *
*** * **** **** ** * * *** * ** * **** *** * *** * * ***** * *** * * **** ** * * * * * *
**** *** ** ** * * *** ** ***** ** *  
  return 0;
}
answered by (273 points)
edited by
0 0
Case 0: Wrong output
Case 1: Wrong output
Case 2: Wrong output
Case 3: Wrong output
0 0
Case 0: Correct output
Case 1: Correct output
Case 2: Correct output
Case 3: Correct output
0 like 0 dislike
Hidden content!
#include <stdio.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
    int a,b;
** * * **** * * *** ** *** ** * , &a, &b);
* * * **** ** ** * * * **** {
** ** * * *** ** *** *** * * ** ******* * * * * * * * ** ** * * ** * * ** *** * * ,a);
* * ******** ******* *** ** *** **** * *** * * ***** **** * ** ** * * * ** *** ** *** * * ***
* *** * ** **** * **** * * * *** ** *** ** *** ***** * ** ********* **** ***** ** *
** *** ***** * ** ** ******* * ** * ** ** ****** ** ** * * * *** * ** * **** ** ** * *
** * ** * ** * *** *** * **** ** * ** ** ***** ****** ** * **** ** * *** *** ** * ** * * ** ** * * ***
* *** ** ** * * ** * * *** * ** ** *** ***** *** ***** * * ** ******* *** ***** * ** ** ****** **
* ** ** *** * *** * * *** * ****** ** ** ** *** ***
    return 0;
}
100/100 answered by (183 points)
0 0
Case 0: Correct output
Case 1: Correct output
Case 2: Correct output
Case 3: Correct output
0 like 0 dislike
Hidden content!
#include <stdio.h>
#include <stdlib.h>


int main(int argc, char *argv[])
{
  int a,b;
* * **** * * * * *** * ,&a,&b);
* ** * * * **** *
***** ** ** ** ****** ** * * ** ** *** * ** *** * ** * ** * * * ******** * * ** * ** ** * * *
* ****** ** * * *** * * **** ** * * * *** * * * * ** * *** * * * * * * *
******* ** ** * **** ****** * ******* * *** **** * ** ** * * * *** * *** ** ** * *
** **** ** ** * * *** * ** ** ** ** * * * ** **** ** ** ** * * * ** * * ******** *** (a==b)
** * **** * ** *** * ** * *** * ** ** * ** ** ** ** ** * * * *** * * * * ** *** **** a);
  
  
* **** * * *** 0;
}
100/100 answered by (192 points)
edited by
0 0
prog.c: In function 'main':
prog.c:8:9: warning: too many arguments for format [-Wformat-extra-args]
   scanf("d%d" , &a, &b);
         ^~~~~
0 0
Case 0: Correct output
Case 1: Correct output
Case 2: Correct output
Case 3: Correct output
0 like 0 dislike
Hidden content!
#include <stdio.h>
#include <stdlib.h>


int main(int argc, char *argv[]) {
******** ** * * *** a, b;
* * * * * *********
* * ** ** * * ***** * **** * * * **** *** * * * * *
***** ** * *** * * ** * i=a-1;
*** *** * * * ** ** * * **
* * ** ***** * **** *** * ** ***** ** *** ** ** ** *** * ********** * ***
* ** ** * ******* ** ** *
* ***** * * * ** *** ** ***** ** *** ** * ** *** * * * * * *
* * ** *** ** * *** * * ** ** * ** * * * * * * * ** * * * *** ** ** * ** * ** **** ** * * ** ** ******
* *** ** * * * * * * ** ** * * * * * **** * * ** * * *** * ** ** * * * * ******* **** * ** *** *** * *** ** ** * ***** *
   
   
* * * * * *********
    system("pause");
* * ** * * * * **** 0;
}
100/100 answered by (221 points)
0 0
Case 0: Correct output
Case 1: Correct output
Case 2: Correct output
Case 3: Correct output
0 like 0 dislike
Hidden content!
#include <stdio.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
    int a,b;
* * ** * ** ** **** **** * ***** ****** * ** ** , &a, &b);
*** * ***** ** * ********* ** {
*** ** ** * * **** ** * * * **** ** * *** * *** * * * * ** **** * * ** *** ** * ** * ,a);
** *** * ** * ** ***** * * ****** * ** ** * *** * ** ** * * * ** * * ** * * *** * * ** *** ***
****** ***** ** ** * ** ** * * ** * *** * ** * * *** * * *** *** * * *** * * **** * *
****** * **** *** ***** * * * ** *** * * ** * * *** ***** **** *** *** *** ** *** * * * * *** ** *
* * *** * ** * * * * ** ** ** *** * * ** ***** * * * * * * ** * * * ** *** ** ** * *** ** ,a);
** *** * ***** * * * ** *** * * ** ** * * * * * * * * ** ** ** ** ** *** ** *
* * ** * * * * ***** * * * ** **
    return 0;
}
answered by (183 points)
0 0
prog.c: In function 'main':
prog.c:9:23: error: expected ';' before string constant
                 printf"%d" ,a);
                       ^~~~
prog.c:9:30: error: expected statement before ')' token
                 printf"%d" ,a);
                              ^
0 like 0 dislike
Hidden content!
#include <stdio.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
    int a,b;
* * **** * * *** * * ** * * * **** * , &a, &b);
* * * * *** *** **** * * * * * * {
** ** * * * * * *** * **** **** ***** * * ** * * * ** *** ** **** * * ** ** * * * * * ** ** * * * ,a);
* ** ** * * * ** * *** ***** * * **** ** * * **** ***** ** * * * * **** ** *** *
* * ** ** * * * ** *** *** * ** * * * ** * ** * * * ***** * ** * * **** ** ******** **
**** * ** **** ** * ****** ********** * * * **** * ** ** * * *** ** ** ** * * * * * **** *** **
****** * * * * * ********* * * * ** ** * * ***** * * ** * * * * ****** ***** * * * * ** ** ** * * ,a);
** ** *** *********** * *** * ** *** ** *** * ** ******** * ** * * ******* * ** ** ** * * * * **
** ****** ** ** *** ** ** * ** ** * *** **
    return 0;
}
answered by (183 points)
0 0
prog.c: In function 'main':
prog.c:9:23: error: expected ';' before string constant
                 printf"%d" ,a);
                       ^~~~
prog.c:9:30: error: expected statement before ')' token
                 printf"%d" ,a);
                              ^
Get it on Google Play Welcome to Peer-Interaction Programming Learning System (PIPLS) LTLab, National DongHwa University
English 中文 Tiếng Việt
IP:172.69.62.28
©2016-2019

Related questions

0 like 0 dislike
22 answers
[Exam] asked Jan 13, 2018 in Final examination by nat236919 (5.9k points)
Available when: Unlimited - Due to: 2018-01-17 16:30
| 34 views
0 like 0 dislike
21 answers
[Exam] asked Jan 13, 2018 in Final examination by nat236919 (5.9k points)
Available when: Unlimited - Due to: Unlimited
| 95 views
0 like 0 dislike
26 answers
[Exam] asked Jan 13, 2018 in Final examination by nat236919 (5.9k points)
Available when: Unlimited - Due to: 2018-01-17 16:30
| 32 views
0 like 0 dislike
21 answers
[Exam] asked Jan 13, 2018 in Final examination by nat236919 (5.9k points)
Available when: Unlimited - Due to: 2018-01-17 16:30
| 23 views
0 like 0 dislike
23 answers
[Exam] asked Jan 13, 2018 in Final examination by nat236919 (5.9k points)
Available when: Unlimited - Due to: 2018-01-17 16:30
| 30 views
8,792 questions
72,353 answers
47,172 comments
2,043 users