Skip to content
Digital Ranger
  • Home
  • Blog
  • Contact
Menu Close
  • Home
  • Blog
  • Contact

Data Structure

  1. Home>
  2. Blog>
  3. Data Structure
Read more about the article Write a program to sort elements of given array having ‘n’ numbers of element, using Selection sort.
Data Structure

Write a program to sort elements of given array having ‘n’ numbers of element, using Selection sort.

Write a program to sort elements of given array having ‘n’ numbers of elements, using Selection sort. #include #include void main() { clrscr(); int size, arr[50], i, j, temp; cout<>size;…

0 Comments
July 6, 2020
Data Structure

Write a program to generate Fibonacci series with the help of recursion.

#include #include int recfib(int n) { if(n==1) { return 0; } else if(n<3) { return 1; } else { return(recfib(n-1)+recfib(n-2)); } } void main() { clrscr(); int n; cout<<"n Fibonacci…

0 Comments
July 6, 2020
Data Structure

Write a program to implement the concept of pointer to array access in functions.

#include #include main() { int *p,i,n; void modify(int *,int); clrscr(); cout<>n; for(i=0;i<n;i++) { cout<<"n A["<<i<>*(p+i); } cout<<"nnn"; cout<<"n Before calling the function for modification elements are :n"; for(i=0;i<n;i++) { cout<<"n…

0 Comments
July 6, 2020
Data Structure

/Wrtite a program to sort elements of given array having ‘n’ numbers of elements, using Insertion sort

#include #include main() { int a[100]; int i,n,temp,j,k; clrscr(); cout<>n; cout<<"enter array :" ; for(i=0;i>a[i]; } for(i=1;i=0 && a[j]>temp) { a[j+1]=a[j]; j--; } a[j+1]=temp; } for(i=0;i<n;i++) { cout<<a[i]; } getch();…

0 Comments
July 6, 2020
Data Structure

Write a program to search an element of choice from the array having ‘n’ number of element, using Linear Search.

#include #include main() { int a[100],i,n,search; cout<>n; cout<<"n enter elements :"; for(i=0;i>a[i]; } cout<>seacrh; for(i=0;i<n;i++) { if(a[i]==search) { cout<<"n found at location :"<<i+1; } else { cout<<"n not found :";…

0 Comments
July 6, 2020
Data Structure

Write a program to sort elements of given array having ‘n’ number of elements,using Merge Sort.

#include #include main() { int a[50],c[100],n,i; void merge(int *,int,int); void mr(int*,int,int,int,int); clrscr(); cout<>n; cout<<"n Enter the elements of array n"; for(i=0;i<n;i++) { cout<<"n a["<<i<>a[i]; } merge(a,0,n-1); cout<<"nnn MERGED ARRAY IN…

0 Comments
July 6, 2020

Recent Posts

  • How to Change WordPress Password From cPanel in phpMyAdmin
  • WordPress Contributors Propose Blocking FLoC in Core
  • High DA PA Web 2.0 Websites List 2021 BY Digital Ranger
  • Introduction to Information Technology
  • Write a program to sort elements of given array having ‘n’ numbers of element, using Selection sort.
  • Write a program to generate Fibonacci series with the help of recursion.

Newsletter

Get all latest content delivered to your email a few times a month. Updates and news about all categories will send to you.
Email is required Email is not valid
This field is required
Thanks for your subscription.
Failed to subscribe, please contact admin.

Follow Us

  • Opens in a new tab
  • Opens in a new tab
  • Opens in a new tab
  • Opens in a new tab

digitalranger.in

Recent Post

  • How to Change WordPress Password From cPanel in phpMyAdmin
  • WordPress Contributors Propose Blocking FLoC in Core
  • High DA PA Web 2.0 Websites List 2021 BY Digital Ranger

Newsletter

Get all latest content delivered to your email a few times a month. Updates and news about all categories will send to you.
Email is required Email is not valid
This field is required
Thanks for your subscription.
Failed to subscribe, please contact admin.

Contact Info

  • Phone:+91 885 123 8176
  • Email:[email protected]Opens in your application
  • Website:digitalranger.in
  • Skype Call UsOpens in your application
© 2021 Digital Ranger. All Rights Reserved With Love by Digital Ranger