Sunday, 28 December 2014

UVA 12577 - Hajj-e-Akbar(c file)

Problem Type : Ad Hoc (Simple String)


#include<stdio.h>
#include<string.h>
#include<math.h>
int main()
{
    char ch[100];
    int len,i,j=0;
    while(gets(ch))
    {
       j++;
      if(strlen(ch)==4)
      {
          printf("Case %d: Hajj-e-Akbar\n",j);
      }
      else if(strlen(ch)==5)
      {
          printf("Case %d: Hajj-e-Asghar\n",j);
      }
      else if(ch[0]=='*')
          break;


}
return 0;
}




No comments:

Post a Comment

ট্রিগার এর মাধ্যমে ডাটা ইনসার্ট - insert data using Database Trigger (Mysql)

সর্বপ্রথম আমরা প্রবলেমটা বুঝিঃ আমি একটা টেবিলের একটা কলামের ভ্যালুর উপর ডিপেন্ড করে আরেকটা কলামে ডাটা insert করব । এই কাজটা ট্রি...