Oh, dude, to print those numbers in QBasic, you can use a simple loop. Just loop from 1 to 5 and print the numbers with spaces in between. It's like making a sandwich, but with numbers instead of bread and cheese. So, like, don't stress, just code it up and hit run. Easy peasy, right?
system.out.println(" print 1-100 numbers");for(i=0;i
pointer variable in c contains the address or the location of the other variable. eg- if a=2 and address of a is 2345. b=&a then b is a pointer which contains 2345 which is the address of a. *b gives value of that is 2.
Do you mean how do you write a Java program to print out those numbers in ascending order? Because you have specified thosenumbers, I can only assume that the following will suffice:-public int main( String[] args ){System.out.println( "0.235 4.62 7.25 7.89 23.5" );}If you want to know how to sort a general array into ascending order, try Google for sorting algorithms, such as "bubble sort", "insertion sort", "heap sort", "quick sort" etc.
output will112123123412345//mycfiles.wordpress.com #include#includevoid main(){int i,j;clrscr();for(i=1;i
#include/* In case pow does not work from math.h */int my_pow( int x, int y ){int i, result = 1;for( i=1; i temp2 ){if ( 1 == j ){printf(" %d, ", i );break;}j--;}else{break;}}while(1);}printf("\n");return 1;}OUTPUT:------------[~/temp-satish]$ ./a.outEnter number of digits :212, 13, 14, 15, 16, 17, 18, 19, 23, 24, 25, 26, 27, 28, 29, 34, 35, 36, 37, 38, 39, 45, 46, 47, 48, 49, 56, 57, 58, 59, 67, 68, 69, 78, 79, 89,[~/temp-satish]$[~/temp-satish]$ ./a.outEnter number of digits :3123, 124, 125, 126, 127, 128, 129, 134, 135, 136, 137, 138, 139, 145, 146, 147, 148, 149, 156, 157, 158, 159, 167, 168, 169, 178, 179, 189, 234, 235, 236, 237, 238, 239, 245, 246, 247, 248, 249, 256, 257, 258, 259, 267, 268, 269, 278, 279, 289, 345, 346, 347, 348, 349, 356, 357, 358, 359, 367, 368, 369, 378, 379, 389, 456, 457, 458, 459, 467, 468, 469, 478, 479, 489, 567, 568, 569, 578, 579, 589, 678, 679, 689, 789,[~/temp-satish]$ ./a.outEnter number of digits :41234, 1235, 1236, 1237, 1238, 1239, 1245, 1246, 1247, 1248, 1249, 1256, 1257, 1258, 1259, 1267, 1268, 1269, 1278, 1279, 1289, 1345, 1346, 1347, 1348, 1349, 1356, 1357, 1358, 1359, 1367, 1368, 1369, 1378, 1379, 1389, 1456, 1457, 1458, 1459, 1467, 1468, 1469, 1478, 1479, 1489, 1567, 1568, 1569, 1578, 1579, 1589, 1678, 1679, 1689, 1789, 2345, 2346, 2347, 2348, 2349, 2356, 2357, 2358, 2359, 2367, 2368, 2369, 2378, 2379, 2389, 2456, 2457, 2458, 2459, 2467, 2468, 2469, 2478, 2479, 2489, 2567, 2568, 2569, 2578, 2579, 2589, 2678, 2679, 2689, 2789, 3456, 3457, 3458, 3459, 3467, 3468, 3469, 3478, 3479, 3489, 3567, 3568, 3569, 3578, 3579, 3589, 3678, 3679, 3689, 3789, 4567, 4568, 4569, 4578, 4579, 4589, 4678, 4679, 4689, 4789, 5678, 5679, 5689, 5789, 6789,[~/temp-satish]$
2345 x 12345 = 28949025
14690
There are only five combinations: 1234, 1235, 1245, 1345 and 2345.
267 234 2665 143 12345 2345 562 5647 345673 735673 3567 36573 356735 3567
1234
2345 + 2345 = 4690
system.out.println(" print 1-100 numbers");for(i=0;i
No; 2345 is odd.
2345-3456 = -1111
2345
The factors of 2345 are: 1, 5, 7, 35, 67, 335, 469, 2345.
6790 + 2345 = 9135