Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

1
232
34543
4567654
can anyone tell me how to slove this c question

Answer Posted / santhoo035

#include<stdio.h>
void di(int n)
{
int c=0,i,j;
for(i=1;i<n;i++)
{
for(j=i;j<=(2*i-1)+(i-1);j++)
{
if(j<(2*i-1))
{
printf("%d",j);
continue;
}
else if(j==(2*i-1))
c=j;
printf("%d",c--);
}
printf("\n");
}
}
int main()
{
di(5);
}

Is This Answer Correct ?    8 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can I rethow can I return a sequence of random numbers which dont repeat at all?

1180


Explain what are global variables and explain how do you declare them?

1148


Explain how can I pad a string to a known length?

1181


Why c is called free form language?

1015


What is the deal on sprintf_s return value?

1115


what do u mean by Direct access files? then can u explain about Direct Access Files?

2076


Explain what is operator promotion?

1069


What’s a signal? Explain what do I use signals for?

1096


What is class and object in c?

1097


Can you write the algorithm for Queue?

2087


How can I find the modification date and time of a file?

1070


pierrot's divisor program using c or c++ code

2222


What is sorting in c plus plus?

960


How do I copy files?

1039


Given two strings S1 and S2. Delete from S2 all those characters which occur in S1 also and finally create a clean S2 with the relevant characters deleted.

1392