Opening Ceremony

Bhim Higher Secondary School Suntopar, Dolakha

Opening Ceremony

Bhim Higher Secondary School Suntopar, Dolakha

JCT Students (First Batch(2069-2070))

Bhim Higher Secondary School Suntopar, Dolakha

Opening Ceremony

Bhim Higher Secondary School Suntopar, Dolakha

Opening Ceremony

Bhim Higher Secondary School Suntopar, Dolakha

Wednesday, August 3, 2016

Program in C for 2 12 22 32 series upto 10th term

/* Program for 2 12 22 32 series upto 10th term */
#include<stdio.h>
#include<conio.h>
void main()
{
    int a=2,i;
    i=1;
    do
    {
        printf(" %d ",a);
        a=a+10;
        i++;
    }
    while(i<=10);
    getch();
}

Monday, August 1, 2016

Fibonacci Series in C Programming using Do While Loop

/* 3 3 6 9 15 fibonacci series upto 10th term */
#include<stdio.h>
#include<conio.h>
void main()
{
    int a=3,b=3,c,i;
    printf("\n %d",a);
    printf(" %d ",b);
    i=1;
    do
    {
        c=a+b;
        printf("%d ",c);
        a=b;
        b=c;
        i++;
    }
    while (i<=10);
    getch();
}

Program in C for 5 25 125 625 series upto 10th term using Do while loop

/* 5 25 125 625 series upto 10th term */
#include<stdio.h>
#include<conio.h>
void main()
{
    int a=5,i;
    i=1;
    do
    {
        printf("%d ",a);
        a=a*5;
        i++;
    }
    while (i<=10);
    getch();
}

Program in C for 1 4 9 16 series upto 20th term using Do- While Loop

/* 1 4 9 16 series upto 20th term */
#include<stdio.h>
#include<conio.h>
void main()
{
    int a,i;
    i=1;
    do
    {
        a=i*i;
        printf("%d ",a);
        i++;
    }
    while (i<=20);
    getch();
}

Program in C for 1 5 9 series upto 10th term

/* 1 5 9 series upto 10th term */
#include<stdio.h>
#include<conio.h>
void main()
{
    int a=1,i;
    i=1;
    do
    {
        printf("%d ",a);
        a+=3;
        i++;
    }
    while (i<=10);
    getch();
}

Sunday, July 31, 2016

Program in C for Traingle : Nested Loop


#include<stdio.h>
#include<conio.h>
void main()
{
    int i,j;
    for(i=1;i<=5;i++)
    {
        for(j=1;j<=i;j++)
        {
            printf("%d",j);
        }
        printf("\n");
    }
    getch();
}

Program in C to find the factorial of a given number


/* Program to find the factorial of a given number */
#include<stdio.h>
#include<conio.h>
void main()
{
    int i, num, fact = 1;

  printf("\n Enter a number to calculate it's factorial : ");
  scanf("%d", &num);

  for (i = 1; i <= num; i++)
    fact = fact * i;

  printf(" Factorial of %d = %d\n", num, fact);
  getch();
}

Program in C to find sum, difference and product of 2 numbers using switch case statement

/* Program in C to find sum, difference and product of 2 numbers using switch case statement */
#include<stdio.h>
#include<conio.h>
void main()
{
    int a,b,ch;
    printf("\n Enter First Number :");
    scanf("%d",&a);
    printf("\n Enter Second Number :");
    scanf("%d",&b);
    printf("\n Enter Your Choice: ( 1. Sum:  2. Difference :  3. Product: ) ");
    scanf("%d",&ch);
    switch (ch)
    {
        case 1:
            {
                printf("\n The sum = %d",a+b);
                break;
            }
            case 2:
            {
                printf("\n The difference = %d",a-b);
                break;
            }
            case 3:
            {
                printf("\n The Product = %d",a*b);
                break;
            }
            default:
            {
                printf("\n out of range");
            }
    }
    getch();
}

Fibonacci Series using while loop in C Programming

/*
#include<stdio.h>
#include<conio.h>
void main()
{
    int a=2, b=2, c, i=1;
    printf("\n %d ",a);
    printf("%d ",b);
    while(i<=10)
    {
        c=a+b;
        printf("%d ",c);
        a=b;
        b=c;
        i++;
    }
    getch();
}
Fibonacci Series using while loop */

Program in C to display first 10 even numbers using while loop

/* Program in C to display first 10 even numbers */
#include<stdio.h>
#include<conio.h>
void main()
{
    int a=2,i=1;
    while(i<=10)
    {
        printf(" %d ",a);
        a=a+2;
        i++;
    }
    getch();
}

Friday, July 29, 2016

Program in C to calculate wage according to given condition

/* A man is paid at the hourly rate of Rs 250 per hour for the first 30 hrs worked in a week.
There after the overtime is paid at 1.5 times the hourly rate for the next 25 hrs
and 2 times the hourly rate for further worked.
WAP to input the number of hours worked in a week and print the weekly wages */
/* Program to Enter 3 Numbers and Find the largest */
#include<stdio.h>
#include<conio.h>
void main()
{
    int hour,wage;
    printf("\n Enter The Worked Hours of week : ");
    scanf("%d",&hour);
    if(hour>0 && hour<=30)
    {
        wage=hour*250;
        printf("\n Wages = %d ",wage);
    }
    else if(hour>30 && hour<=55)
    {
        wage=(hour*250*1.5);
        printf("\n Wage = %d ",wage);
    }
    else if(hour>55)
    {
        wage=(hour*250*2);
        printf("\n Wage = %d ",wage);
    }
    else{
            printf("\Wrong Input, Try Again");
    }
    getch();

}

Tuesday, July 26, 2016

Program in C For Series 2,5,10,17 ...... upto nth term and sum too

/* Program in C For Series 2 5 10 17 ...... upto nth term and sum too */
#include<stdio.h>
#include<conio.h>
void main()
{
    int i,calc=0,num=0,sum=0;
    printf("\n Enter any number :");
    scanf("%d",&num);
    for(i=1;i<=num;i++)
    {
    calc=i*i+1;
    printf(" %d ",calc);
    sum=sum+calc;
    }
    printf("\n Sum = %d :",sum);
    getch();
}

Program in C For Series 2 4 8 16...... upto nth term

/* Program in C For Series 2 4 8 16...... upto nth term */
#include<stdio.h>
#include<conio.h>
void main()
{
    int a=2,i,num;
    printf("\n Enter any number :");
    scanf("%d",&num);
    for(i=1;i<=num;i++)
    {
    printf(" %d ",a);
    a=a*2;
    }
    getch();
}

Friday, July 22, 2016

Fibonacci Series in C Programming

/* Program in C to print fibonacci series upto 10th term */
#include<stdio.h>
#include<conio.h>
void main()
{
  int a=2,b=2,c,i;
  printf(" %d ",a);
  printf(" %d ",b);
  for(i=1;i<=10;i++)
  {
      c=a+b;
     printf("%d ",c);
     a=b;
     b=c;
  }
  getch();
}