Computer Science, asked by SohanSr2900, 11 months ago

What will be the output of the following programs?
(a) # include < iostream.h >
void main ( )
{
int a [ 5 ], t ;
for (i= 0; i < 5; i ++ )
a [i] = 5 * i;
for (i = 0; i < 5; i ++)
cout << a [ i ];
}
(b) # include < iostream.h >
void main ( )
{
char title [ ] = "Computer";
for ( int i = 0; title [ i ]; i ++)
cout << "\n" << (title + i);

Answers

Answered by Anonymous
4

What will be the output of the following programs?

(a) # include < iostream.h >

void main ( )

{

int a [ 5 ], t ;

for (i= 0; i < 5; i ++ )

a [i] = 5 * i;

for (i = 0; i < 5; i ++)

cout << a [ i ];

}

(b) # include < iostream.h >

void main ( )

{

char title [ ] = "Computer";

for ( int i = 0; title [ i ]; i ++)

cout << "\n" << (title + i);

PLEASE MAKE ME AS A BRAINLIST ANSWER

Similar questions