Programmator
Programmator
  • Home
  • Download
  • Social
    • YouTube
    • Instagram
    • Facebook
    • Telegram
  • Features
    • C/C++
    • Java
  • Contact Us
Write a program to access elements using pointer

In this program, we will learn to create a C program that will Access Elements of an Array Using Pointer using C programming.
Prerequisites

Before starting with this tutorial we assume that you are best aware of the following C programming topics:

  • Operators in C Programming.
  • Basic Input and Output function in C Programming.
  • Basic C programming.
  • For loop in C Programming.
  • Using pointer in C programming.
Access Elements of an Array Using Pointer:-
As we all know array is a collection of similar data type elements. In an array, only one variable is declared which can store multiple values. First will take the elements of an array from the user.  Then will pass the elements address to the pointer and the will print the elements of array /Access Elements of an Array Using Pointer with the help of C Programming Language.
Pointer is a variable that can store the address of another variable.

  •  Program:

#include<stdio.h>

int main()
{
    int data[5];
    printf("Enter the elements: \n");
    for(int i=0; i<5; ++i)
    scanf("%d", data+i);

    printf("You entered: \n");
    for(int i=0; i<5; ++i)
    printf("%d\n", *(data+i));
    return 0;
}

  •  Output:

Enter the elements: 2 1 5 4 3 You entered: 2 1 5 4 3

  • Visit:

Write a C program to computer Fahrenheit from centigrade ( f=1.8*c+32 ) Here
Write a C program to find out distance travelled by the equation d=ut+at^2 Here
Write a C program to find that the accepted number is negative or positive or zero Here
Write a program to read mark of a student from keyboard the student is pass or fail ( using if else ) Here
Write a program to read three numbers from keyboard and find out maximum out of these three. (nested if else) Here
Write a program to check whether the entered character is capital, small letter, digit or any special character Here
Write a program to read marks from keyboard and your program should display equivalent grade according to following table (if else ladder) Here
Write a C program to prepare pay slip using following data Here
Write a C program to read no 1 to 7 and print relatively day Sunday to Saturday Here
Write a C program to find out the Maximum and Minimum number from given 10 numbers Here
Write a C program to input an integer number and check the last digit of number is even or odd Here 
Write a C program to find factorial of a given number Here
Write a C program to reverse a number Here
Write a C program to generate first n number of Fibonacci series Here
Write a C program to find out sum of first and last digit of a given number Here
Write a C program to find the sum and average of different numbers Here
Write a program to calculate average and total of 5 students for 3 subjects Here
Read five persons height and weight and count the number of person having height greater than 170 and weight less than 50 Here
Write a program to check whether the given number is prime or not Here
Write a program to evaluate the series 1^2+2^2+2+3^2+……+n^2 Here
Write a C program to find 1+1/2+1/3+1/4+....+1/n Here
Write a C program to find 1+1/2!+1/3!+1/4!+.....+1/n! Here
Write a C program to evaluate the series sum=1-x+x^2/2!-x^3/3!+x^4/4!......-x^9/9! Here
Write a C program to read and store the roll no and marks of 20 students using array Here
Write a C program to find out which number is even or odd from list of 10 number using array Here
Write a program to find maximum element from 1-Dimensional array Here
Write a C program to calculate the average, geometric and harmonic mean of n elements in a array Here
Write a program to delete a character in given string Here
Write a program to replace a character in given string Here
Write a program to find a character from given string Here
Write a program to sort given array in ascending order Here
Write a program to reverse string Here
Write a program to convert string into upper case Here
Write a program that defines a function to add first n numbers Here
Write a function in the program to return 1 if number is prime otherwise return 0 Here
Write a function Exchange to interchange the values of two variables, say x and y. illustrate the use of this function in a calling function Here
Write a C program to use recursive calls to evaluate F(x) = x – x3 / 3! + x5 / 5 ! – x7 / 7! + … xn/ n! Here
Write a program to find factorial of a number using recursion Here
Write a function that will scan a character string passed as an argument and convert all lowercase character into their uppercase equivalents Here
Write a program to read structure elements from keyboard Here
Write a C program to print the address of character and the character of string using pointer

In this program we are going to print address of character and string using pointers. As we know a string is a stream of characters and each character holds different address. So to print address of each character's address we are going to take a pointer array to hold address of each character as in the following example.

  • Program:

#include<stdio.h>
#include<conio.h>
#include<string.h>
void main()
{

    char str[30]="Goeduhub Technologies";
    char c='A';
    int i;

    char *ptr_str[30];
    char *ptr_c=&c;

    for(i=0;i<strlen(str);i++)
    ptr_str[i]=&str[i];


    //Printing value and address of variables on output window
    printf("\nString Entered is : %s\n Address of string :",str);
    for(i=0;i<strlen(str);i++)
    printf("\n%c's address : %p",str[i],ptr_str[i]);
    printf("\nValue of c = %c\nAddress of c = %p",c,ptr_c);
    getch();
}

  • Output:

String Entered is : Goeduhub Technologies Address of string : G's address : 0061FEFA o's address : 0061FEFB e's address : 0061FEFC d's address : 0061FEFD u's address : 0061FEFE h's address : 0061FEFF u's address : 0061FF00 b's address : 0061FF01 's address : 0061FF02 T's address : 0061FF03 e's address : 0061FF04 c's address : 0061FF05 h's address : 0061FF06 n's address : 0061FF07 o's address : 0061FF08 l's address : 0061FF09 o's address : 0061FF0A g's address : 0061FF0B i's address : 0061FF0C e's address : 0061FF0D s's address : 0061FF0E Value of c = A Address of c = 0061FEF9

  •  Visit:

Write a C program to computer Fahrenheit from centigrade ( f=1.8*c+32 ) Here
Write a C program to find out distance travelled by the equation d=ut+at^2 Here
Write a C program to find that the accepted number is negative or positive or zero Here
Write a program to read mark of a student from keyboard the student is pass or fail ( using if else ) Here
Write a program to read three numbers from keyboard and find out maximum out of these three. (nested if else) Here
Write a program to check whether the entered character is capital, small letter, digit or any special character Here
Write a program to read marks from keyboard and your program should display equivalent grade according to following table (if else ladder) Here
Write a C program to prepare pay slip using following data Here
Write a C program to read no 1 to 7 and print relatively day Sunday to Saturday Here
Write a C program to find out the Maximum and Minimum number from given 10 numbers Here
Write a C program to input an integer number and check the last digit of number is even or odd Here 
Write a C program to find factorial of a given number Here
Write a C program to reverse a number Here
Write a C program to generate first n number of Fibonacci series Here
Write a C program to find out sum of first and last digit of a given number Here
Write a C program to find the sum and average of different numbers Here
Write a program to calculate average and total of 5 students for 3 subjects Here
Read five persons height and weight and count the number of person having height greater than 170 and weight less than 50 Here
Write a program to check whether the given number is prime or not Here
Write a program to evaluate the series 1^2+2^2+2+3^2+……+n^2 Here
Write a C program to find 1+1/2+1/3+1/4+....+1/n Here
Write a C program to find 1+1/2!+1/3!+1/4!+.....+1/n! Here
Write a C program to evaluate the series sum=1-x+x^2/2!-x^3/3!+x^4/4!......-x^9/9! Here
Write a C program to read and store the roll no and marks of 20 students using array Here
Write a C program to find out which number is even or odd from list of 10 number using array Here
Write a program to find maximum element from 1-Dimensional array Here
Write a C program to calculate the average, geometric and harmonic mean of n elements in a array Here
Write a program to delete a character in given string Here
Write a program to replace a character in given string Here
Write a program to find a character from given string Here
Write a program to sort given array in ascending order Here
Write a program to reverse string Here
Write a program to convert string into upper case Here
Write a program that defines a function to add first n numbers Here
Write a function in the program to return 1 if number is prime otherwise return 0 Here
Write a function Exchange to interchange the values of two variables, say x and y. illustrate the use of this function in a calling function Here
Write a C program to use recursive calls to evaluate F(x) = x – x3 / 3! + x5 / 5 ! – x7 / 7! + … xn/ n! Here
Write a program to find factorial of a number using recursion Here
Write a function that will scan a character string passed as an argument and convert all lowercase character into their uppercase equivalents Here
Write a program to read structure elements from keyboard Here
Write a C program to swap the two values using pointers

Method 1.

In this program we are going to swap two numbers using pointers. The pointer will be used to hold the address of the variable and using pointer address of the variables will be swepped. In the following example we are going to implement this theory. 

  •  Program:

#include<stdio.h>
#include<conio.h>
   
void main()
{

//Declaration of variables and pointer variables
int x,y,*ptr_x,*ptr_y,temp;  

//Insert value of x and y
printf("Enter the value of x and y\n");
scanf("%d%d", &x, &y);

//Printing value before swapping
printf("Before Swapping\nx = %d\ny = %d\n", x, y);

//Assigning address of variables to pointers
ptr_x = &x;
ptr_y = &y;

//Swapping pointer address with the help of temp variable
temp = *ptr_y;
*ptr_y = *ptr_x;
*ptr_x = temp;

//printing values of x and y
printf("After Swapping\nx = %d\ny = %d\n", x, y);
getch();
}

  •  Output:

Enter the value of x and y 100 123 Before Swapping x = 100 y = 123 After Swapping x = 123 y = 100


Method 2.

Logic To Swap Two Numbers using Pointers and Function

We ask the user to enter values for variable a and b. We pass the address of variable a and b to function swap().

Inside function swap() we take a local variable temp. Since address of variable a and b are passed to swap() method, we take 2 pointer variables *x and *y. Pointer variable x holds the address of a and pointer variable y holds the address of b. Using below logic we swap the values present at address a( or x ) and b( or y ).

temp = *x;
*x = *y;
*y = temp;

Since we are directly changing the value present at particular address, the value gets reflected throughout the program and not just inside particular function. That’s why we are able to print the result inside main function and the values of variable a and b are swapped, without getting any returned value from function swap().

  •  Program:

#include<stdio.h>
#include<conio.h>
   
void swap(int*, int*);
int main()
{
    int a, b;

    printf("Enter the value for a and b\n");
    scanf("%d%d", &a, &b);

    printf("\n\nBefore swapping: a = %d and b = %d\n",a, b);
    swap(&a, &b);
    printf("\nAfter sawpping: a = %d and b = %d\n", a, b);
    return 0;
}
void swap(int *x, int *y)
{
    int temp;

    temp = *x;
    *x = *y;
    *y = temp;
}

  •  Output:

Enter the value for a and b 100 200 Before swapping: a = 100 and b = 200 After sawpping: a = 200 and b = 100

  •  Visit:

Write a C program to computer Fahrenheit from centigrade ( f=1.8*c+32 ) Here
Write a C program to find out distance travelled by the equation d=ut+at^2 Here
Write a C program to find that the accepted number is negative or positive or zero Here
Write a program to read mark of a student from keyboard the student is pass or fail ( using if else ) Here
Write a program to read three numbers from keyboard and find out maximum out of these three. (nested if else) Here
Write a program to check whether the entered character is capital, small letter, digit or any special character Here
Write a program to read marks from keyboard and your program should display equivalent grade according to following table (if else ladder) Here
Write a C program to prepare pay slip using following data Here
Write a C program to read no 1 to 7 and print relatively day Sunday to Saturday Here
Write a C program to find out the Maximum and Minimum number from given 10 numbers Here
Write a C program to input an integer number and check the last digit of number is even or odd Here 
Write a C program to find factorial of a given number Here
Write a C program to reverse a number Here
Write a C program to generate first n number of Fibonacci series Here
Write a C program to find out sum of first and last digit of a given number Here
Write a C program to find the sum and average of different numbers Here
Write a program to calculate average and total of 5 students for 3 subjects Here
Read five persons height and weight and count the number of person having height greater than 170 and weight less than 50 Here
Write a program to check whether the given number is prime or not Here
Write a program to evaluate the series 1^2+2^2+2+3^2+……+n^2 Here
Write a C program to find 1+1/2+1/3+1/4+....+1/n Here
Write a C program to find 1+1/2!+1/3!+1/4!+.....+1/n! Here
Write a C program to evaluate the series sum=1-x+x^2/2!-x^3/3!+x^4/4!......-x^9/9! Here
Write a C program to read and store the roll no and marks of 20 students using array Here
Write a C program to find out which number is even or odd from list of 10 number using array Here
Write a program to find maximum element from 1-Dimensional array Here
Write a C program to calculate the average, geometric and harmonic mean of n elements in a array Here
Write a program to delete a character in given string Here
Write a program to replace a character in given string Here
Write a program to find a character from given string Here
Write a program to sort given array in ascending order Here
Write a program to reverse string Here
Write a program to convert string into upper case Here
Write a program that defines a function to add first n numbers Here
Write a function in the program to return 1 if number is prime otherwise return 0 Here
Write a function Exchange to interchange the values of two variables, say x and y. illustrate the use of this function in a calling function Here
Write a C program to use recursive calls to evaluate F(x) = x – x3 / 3! + x5 / 5 ! – x7 / 7! + … xn/ n! Here
Write a program to find factorial of a number using recursion Here
Write a function that will scan a character string passed as an argument and convert all lowercase character into their uppercase equivalents Here
Write a program to read structure elements from keyboard Here
In this tutorial, we will learn about how to create a program in C that prints address of any variable. At last we will also learn about printing an address of a variable in C using pointer.

Definition:
Pointer is the variable that holds the address of another variable.

Syntax:
pointer_vaibale = &variable;
  •  Program:

#include <stdio.h>

int main(void)
{
    int i=15;
    int *p;
    p=&i;
    printf("\n Address of Variable i = %u",p);
    return 0;
}

  •  Output:

Address of Variable i = 6422296

  •  Visit :

Write a C program to computer Fahrenheit from centigrade ( f=1.8*c+32 ) Here
Write a C program to find out distance travelled by the equation d=ut+at^2 Here
Write a C program to find that the accepted number is negative or positive or zero Here
Write a program to read mark of a student from keyboard the student is pass or fail ( using if else ) Here
Write a program to read three numbers from keyboard and find out maximum out of these three. (nested if else) Here
Write a program to check whether the entered character is capital, small letter, digit or any special character Here
Write a program to read marks from keyboard and your program should display equivalent grade according to following table (if else ladder) Here
Write a C program to prepare pay slip using following data Here
Write a C program to read no 1 to 7 and print relatively day Sunday to Saturday Here
Write a C program to find out the Maximum and Minimum number from given 10 numbers Here
Write a C program to input an integer number and check the last digit of number is even or odd Here 
Write a C program to find factorial of a given number Here
Write a C program to reverse a number Here
Write a C program to generate first n number of Fibonacci series Here
Write a C program to find out sum of first and last digit of a given number Here
Write a C program to find the sum and average of different numbers Here
Write a program to calculate average and total of 5 students for 3 subjects Here
Read five persons height and weight and count the number of person having height greater than 170 and weight less than 50 Here
Write a program to check whether the given number is prime or not Here
Write a program to evaluate the series 1^2+2^2+2+3^2+……+n^2 Here
Write a C program to find 1+1/2+1/3+1/4+....+1/n Here
Write a C program to find 1+1/2!+1/3!+1/4!+.....+1/n! Here
Write a C program to evaluate the series sum=1-x+x^2/2!-x^3/3!+x^4/4!......-x^9/9! Here
Write a C program to read and store the roll no and marks of 20 students using array Here
Write a C program to find out which number is even or odd from list of 10 number using array Here
Write a program to find maximum element from 1-Dimensional array Here
Write a C program to calculate the average, geometric and harmonic mean of n elements in a array Here
Write a program to delete a character in given string Here
Write a program to replace a character in given string Here
Write a program to find a character from given string Here
Write a program to sort given array in ascending order Here
Write a program to reverse string Here
Write a program to convert string into upper case Here
Write a program that defines a function to add first n numbers Here
Write a function in the program to return 1 if number is prime otherwise return 0 Here
Write a function Exchange to interchange the values of two variables, say x and y. illustrate the use of this function in a calling function Here
Write a C program to use recursive calls to evaluate F(x) = x – x3 / 3! + x5 / 5 ! – x7 / 7! + … xn/ n! Here
Write a program to find factorial of a number using recursion Here
Write a function that will scan a character string passed as an argument and convert all lowercase character into their uppercase equivalents Here
Write a program to read structure elements from keyboard Here
Design a structure student_record to contain name, branch and total marks obtained. Develop a program to read data for 10 students in a class and print them

In this program, a structure (student) is created which contains name, Branch and marks as its data member. Then, an array of structure of 5 elements is created. Then, data (name, Branch and marks) for 5 elements is asked to user and stored in array of structure. Finally, the data entered by user is displayed.

Here is source code of the C program to calculate The Marks Branch and Name of Students . The C program is successfully compiled. The program output is also shown below.

  •  Program:

#include <stdio.h>

struct student_record
{
    char name[20];
    char branch[20];
    int total_marks;
}p[5];

int main(void)
{
    int i=0,n=5;
 
    for(i=0;i<n;i++)
    {
        printf("\n Enter Student Name : ");
        scanf("%s",p[i].name);
        printf("\n Enter Students Branch : ");
        scanf("%s",p[i].branch);
        printf("\n Enter Students Marks : ");
        scanf("%d",&p[i].total_marks);
    }
 
    for(i=0;i<n;i++)
    {
        printf("\n Student %d Detail",i+1);
        printf("\n Name        = %s",p[i].name);
        printf("\n Branch      = %s",p[i].branch);
        printf("\n Total marks = %d",p[i].total_marks);
    }
    return 0;
}

  •  Output:

Enter Student Name : Nilesh Enter Students Branch : IT Enter Students Marks : 89 Enter Student Name : Ila Enter Students Branch : CE Enter Students Marks : 90 Enter Student Name : Vishu Enter Students Branch : CS Enter Students Marks : 80 Enter Student Name : Krishna Enter Students Branch : CSE Enter Students Marks : 87 Enter Student Name : Kishn Enter Students Branch : BA Enter Students Marks : 91 Student 1 Detail Name = Nilesh Branch = IT Total marks = 89 Student 2 Detail Name = Ila Branch = CE Total marks = 90 Student 3 Detail Name = Vishu Branch = CS Total marks = 80 Student 4 Detail Name = Krishna Branch = CSE Total marks = 87 Student 5 Detail Name = Kishn Branch = BA Total marks = 91

  •  Visit:

Write a C program to computer Fahrenheit from centigrade ( f=1.8*c+32 ) Here
Write a C program to find out distance travelled by the equation d=ut+at^2 Here
Write a C program to find that the accepted number is negative or positive or zero Here
Write a program to read mark of a student from keyboard the student is pass or fail ( using if else ) Here
Write a program to read three numbers from keyboard and find out maximum out of these three. (nested if else) Here
Write a program to check whether the entered character is capital, small letter, digit or any special character Here
Write a program to read marks from keyboard and your program should display equivalent grade according to following table (if else ladder) Here
Write a C program to prepare pay slip using following data Here
Write a C program to read no 1 to 7 and print relatively day Sunday to Saturday Here
Write a C program to find out the Maximum and Minimum number from given 10 numbers Here
Write a C program to input an integer number and check the last digit of number is even or odd Here 
Write a C program to find factorial of a given number Here
Write a C program to reverse a number Here
Write a C program to generate first n number of Fibonacci series Here
Write a C program to find out sum of first and last digit of a given number Here
Write a C program to find the sum and average of different numbers Here
Write a program to calculate average and total of 5 students for 3 subjects Here
Read five persons height and weight and count the number of person having height greater than 170 and weight less than 50 Here
Write a program to check whether the given number is prime or not Here
Write a program to evaluate the series 1^2+2^2+2+3^2+……+n^2 Here
Write a C program to find 1+1/2+1/3+1/4+....+1/n Here
Write a C program to find 1+1/2!+1/3!+1/4!+.....+1/n! Here
Write a C program to evaluate the series sum=1-x+x^2/2!-x^3/3!+x^4/4!......-x^9/9! Here
Write a C program to read and store the roll no and marks of 20 students using array Here
Write a C program to find out which number is even or odd from list of 10 number using array Here
Write a program to find maximum element from 1-Dimensional array Here
Write a C program to calculate the average, geometric and harmonic mean of n elements in a array Here
Write a program to delete a character in given string Here
Write a program to replace a character in given string Here
Write a program to find a character from given string Here
Write a program to sort given array in ascending order Here
Write a program to reverse string Here
Write a program to convert string into upper case Here
Write a program that defines a function to add first n numbers Here
Write a function in the program to return 1 if number is prime otherwise return 0 Here
Write a function Exchange to interchange the values of two variables, say x and y. illustrate the use of this function in a calling function Here
Write a C program to use recursive calls to evaluate F(x) = x – x3 / 3! + x5 / 5 ! – x7 / 7! + … xn/ n! Here
Write a program to find factorial of a number using recursion Here
Write a function that will scan a character string passed as an argument and convert all lowercase character into their uppercase equivalents Here
Write a program to read structure elements from keyboard Here
Define a structure called cricket that will describe the following information
Player name
Team name
Batting average
Using cricket, declare an array player with 5 elements and write a C program to read the information about all the 5 players and print team wise list containing names of players with their batting average.

In this program we are going to implement a structure called cricket which will hold three members as player name, team name, batting average. We will take input of these information from user and then print it to output window.

  •  Program:

#include<stdio.h>
#include<conio.h>
#include<string.h>

struct cricket
{
    char pname[20];
    char tname[20];
    float bavg;
};

int main()
{
    struct cricket s[5],t;
    int i,j,n=5;
    float p;

    printf("\nEnter data of %d players",n);
    for(i=0;i<n;i++)
    {
        printf("\nEnter PName, TName,s BAvg for player-%d = ",i+1);
        scanf("%s %s %f",s[i].pname,s[i].tname,&p);
        s[i].bavg=p;
    }

    for(i=1;i<=n-1;i++)
    {
        for(j=1;j<=n-i;j++)
        {
            if(strcmp(s[j-1].tname,s[j].tname)>0)
            {
                t=s[j-1];
                s[j-1]=s[j];
                s[j]=t;
            }
        }
    }

    printf("\nAfter teamwise sorting... Player list is ");
    for(i=0;i<n;i++)
    {
        printf("\n%-20s %-20s %.2f",s[i].pname,s[i].tname,s[i].bavg);
    }

    getch();
    return 0;
}

  •  Output:

 

Enter data of 5 players Enter PName, TName,s BAvg for player-1 = sachin India 98 Enter PName, TName,s BAvg for player-2 = rahul India 45 Enter PName, TName,s BAvg for player-3 = jointy Australia 75 Enter PName, TName,s BAvg for player-4 = imran Pakistan 65 Enter PName, TName,s BAvg for player-5 = shen Australia 29 After teamwise sorting... Player list is jointy Australia 75.00 shen Australia 29.00 sachin India 98.00 rahul India 45.00 imran Pakistan 65.00

  •  Visit:

Write a C program to computer Fahrenheit from centigrade ( f=1.8*c+32 ) Here
Write a C program to find out distance travelled by the equation d=ut+at^2 Here
Write a C program to find that the accepted number is negative or positive or zero Here
Write a program to read mark of a student from keyboard the student is pass or fail ( using if else ) Here
Write a program to read three numbers from keyboard and find out maximum out of these three. (nested if else) Here
Write a program to check whether the entered character is capital, small letter, digit or any special character Here
Write a program to read marks from keyboard and your program should display equivalent grade according to following table (if else ladder) Here
Write a C program to prepare pay slip using following data Here
Write a C program to read no 1 to 7 and print relatively day Sunday to Saturday Here
Write a C program to find out the Maximum and Minimum number from given 10 numbers Here
Write a C program to input an integer number and check the last digit of number is even or odd Here 
Write a C program to find factorial of a given number Here
Write a C program to reverse a number Here
Write a C program to generate first n number of Fibonacci series Here
Write a C program to find out sum of first and last digit of a given number Here
Write a C program to find the sum and average of different numbers Here
Write a program to calculate average and total of 5 students for 3 subjects Here
Read five persons height and weight and count the number of person having height greater than 170 and weight less than 50 Here
Write a program to check whether the given number is prime or not Here
Write a program to evaluate the series 1^2+2^2+2+3^2+……+n^2 Here
Write a C program to find 1+1/2+1/3+1/4+....+1/n Here
Write a C program to find 1+1/2!+1/3!+1/4!+.....+1/n! Here
Write a C program to evaluate the series sum=1-x+x^2/2!-x^3/3!+x^4/4!......-x^9/9! Here
Write a C program to read and store the roll no and marks of 20 students using array Here
Write a C program to find out which number is even or odd from list of 10 number using array Here
Write a program to find maximum element from 1-Dimensional array Here
Write a C program to calculate the average, geometric and harmonic mean of n elements in a array Here
Write a program to delete a character in given string Here
Write a program to replace a character in given string Here
Write a program to find a character from given string Here
Write a program to sort given array in ascending order Here
Write a program to reverse string Here
Write a program to convert string into upper case Here
Write a program that defines a function to add first n numbers Here
Write a function in the program to return 1 if number is prime otherwise return 0 Here
Write a function Exchange to interchange the values of two variables, say x and y. illustrate the use of this function in a calling function Here
Write a C program to use recursive calls to evaluate F(x) = x – x3 / 3! + x5 / 5 ! – x7 / 7! + … xn/ n! Here
Write a program to find factorial of a number using recursion Here
Write a function that will scan a character string passed as an argument and convert all lowercase character into their uppercase equivalents Here
Write a program to read structure elements from keyboard Here
Newer Posts Older Posts Home

ABOUT

I could look back at my life and get a good story out of it. It's a picture of somebody trying to figure things out.

SUBSCRIBE & FOLLOW

POPULAR POSTS

  • Write a C program to enter a distance in to kilometer and convert it in to meter, feet, inches and centimeter
  • Write a C program to computer Fahrenheit from centigrade ( f=1.8*c+32 )
  • Write a C program to interchange two numbers
  • Write a C program to read and store the roll no and marks of 20 students using array
  • Write a C program to evaluate the series sum=1-x+x^2/2!-x^3/3!+x^4/4!......-x^9/9!

Advertisement

👆 Shopping 👆

Powered by Blogger

Archive

  • February 20241
  • January 20242
  • November 20234
  • October 20236
  • September 20236
  • August 20235
  • April 20231
  • March 20231
  • October 20221
  • August 20223
  • July 20222
  • May 20223
  • April 20222
  • March 20221
  • January 20221
  • December 20216
  • November 20214
  • October 20211
  • September 20216
  • August 202127
  • July 20216

Report Abuse

Copyright

  • Home
  • About us
  • Privacy Policy
  • Disclaimer
  • Contact Us

About Me

Nilesh Patel
View my complete profile

Copyright © Programmator. Designed by OddThemes