Let's Go with OOP

Let's Go with OOP Let Start to love Programming

10/03/2018

Margaret Hamilton standing next to the code she wrote which took Apollo 11 to the moon.

09/03/2018

let's trying some OOP :P oops

30/11/2017

Write a C program to find out second largest number from an arbitrary integer data-set.
Example:
User input: 8 2 1 6 4 5 3 7 Output: 7

WAP in C to perform swapping between two integer variables without using third variable.

WAP in C to perform sorting on integer array. Runtime complexity of your sorting subroutine should not excide O(nlog(n)). No auxiliary array is allowed in your program.

WAP in C to implement a Queue data-structure in circular manner.

WAP in C to perform matrix multiplication. Provide an error message if dimensions of matrixes do not agree.

WAP in C to identify the element that appears once in the given array of size
2n+1. Assume every other elements of the array appear exactly twice. Expected time complexity of your program is O(n).
Sample input/output:
Input: {1,3,4,4,5,7,3,1,7} Output: 5

WAP in C to represent a polynomial using linked-list data structure.

18/11/2017

1) Write a C program to find out second largest number from an arbitrary integer data-set.
Example:
User input: 8 2 1 6 4 5 3 7 Output: 7

2) WAP in C to perform swapping between two integer variables without using third variable
3) WAP in C to perform sorting on integer array. Runtime complexity of your sorting subroutine should not excide O(nlog(n)). No auxiliary array is allowed in your program.

4) WAP in C to implement a Queue data-structure in circular manner.

5) WAP in C to perform matrix multiplication. Provide an error message if dimensions of matrixes do not agree.

6) WAP in C to identify the element that appears once in the given array of size 2n+1. Assume every other elements of the array appear exactly twice. Expected time complexity of your program is O(n).
Sample input/output:
Input: {1,3,4,4,5,7,3,1,7} Output: 5

7) WAP in C to represent a polynomial using linked-list data structure.

:) Happy Programming

14/09/2017
Code to win . Code to achieve . Code for fun. Coding is everything to us
14/09/2017

Code to win . Code to achieve . Code for fun. Coding is everything to us

05/09/2017

ALL POSSIBLE ARRAY OPERATIONS:

// array_all.cpp : Defines the entry point for the console application.
//




void insert(int*,int);
void del(int*,int);
void display(int*,int);
void reverse(int*, int);
void remove_duplicate(int*, int);
void search(int*, int);
void replace(int*, int);
int main()
{
int a[20],no, choice,b[20],i,e=1,no1;
printf("how many no to be inserted: ");
scanf_s("%d", &no);
for (i = 0; i < no; i++)
{
printf("no[%d]=", e);
scanf_s("%d", &a[i]);
e++;
}
system("cls");
printf("1=DISPLAY 2=INSERTION 3=DELETION 4=REVERSE 5=REMOVE DUPLICATE 6=SEARCH 7=REPLACE 0=EXIT\n");
while (1)
{
printf("\nWHAT DO YOU WANT TO DO: ");
scanf_s("%d", &choice);
switch (choice)
{
case 1:display(a, no);
break;
case 2:insert(a, no);
no = no + 1;
break;
case 3:del(a, no);
no = no - 1;
break;
case 0:exit(0);
break;
case 4:reverse(a, no);
break;
case 5:remove_duplicate(a, no);
break;
case 6:search(a, no);
break;
case 7:replace(a, no);
break;
default:printf(".......III......");
break;
system("cls");
}
}
_getch();
}
void display(int *a,int no)
{
int j, f = 1;
printf("elements are: ");
for (j = 0; j < no; j++)
{
printf("\nno[%d]=%d", f, *(a+j));
f++;
}
}
void insert(int *a, int no)
{
int pos, val,temp,c;
printf("enter the pos: ");
scanf_s("%d",&pos);
printf("enter thye valoe: ");
scanf_s("%d",&val);
for (c = no - 1; c >= pos - 1; c--)
a[c + 1] = a[c];

a[pos - 1] = val;
}
void del(int *a, int no)
{
int element,found=0,j,pos;
printf("Enter the element to be deleted\n");
scanf_s("%d", &element);
for (j = 0; j < no; j++)
{
if (a[j] == element)
{
found = 1;
pos = j;
break;
}
}
if (found == 1)
{
for (j = pos; j < no - 1; j++)
{
a[j] = a[j + 1];
}
}
else
printf("Element %d is not found in the vector\n", element);
}
void reverse(int *a,int no)
{
int k, j, temp;
for (k = 0, j = k + no - 1; k < j; k++, j--)
{
temp = *(a + k);
*(a + k) = *(a + j);
*(a + j) = temp;
}
}
void remove_duplicate(int *a, int no)
{
int i,j,e=1,c,position,n,temp=0;
for (i = 0; i < no-1; i++)
{
for (j = i + 1; j < no; j++)
{
if (a[i] == a[j])
{
position = j;
for (c = position; c < no - 1; c++)
{
a[c] = a[c + 1];
}
no = no - 1;
}
}
}
for (c = 0; c < no; c++)
{
printf("%d ", a[c]);
}
}
void search(int *a, int no)
{
int search,i;
printf("ENTER THE ELEMENT TO SEARCH: ");
scanf_s("%d", &search);
i = 0;
while (i < no && search != a[i]) {
i++;
}
if (i < no)
{
printf("Number found at the location = %d", i);
}
else
{
printf("Number not found");
}

}
void replace(int *a, int no)
{
int x, y,i;
display(a,no);
printf("\nenter the element to replace : ");
scanf_s("%d", &x);
printf("\nreplace with : ");
scanf_s("%d", &y);
i = 0;
while (i < no && x!= a[i])
{
i++;
}
if (i < no)
{
a[i] = y;
}
else
{
printf("Number not found");
}
}

It removes the duplicate elements from an array. it is a temporary I am working an another which wiil find the duplicate...
02/09/2017

It removes the duplicate elements from an array. it is a temporary I am working an another which wiil find the duplicate elements from the resultant array and publish the fresh array. If any one can send me suggestions. Thanks you. :) .

23/07/2017
IS THE PROGRAM  IMPRESSIVE? OR NEED TO DEVELOP MORE? IT IS ONLY ON QUADRATIC EQUATION๐Ÿ˜Š๐Ÿ˜Š๐Ÿ˜Š๐Ÿ˜Š๐Ÿ˜Š
04/06/2017

IS THE PROGRAM IMPRESSIVE? OR NEED TO DEVELOP MORE? IT IS ONLY ON QUADRATIC EQUATION๐Ÿ˜Š๐Ÿ˜Š๐Ÿ˜Š๐Ÿ˜Š๐Ÿ˜Š

Address

Kolkata

Website

Alerts

Be the first to know and let us send you an email when Let's Go with OOP posts news and promotions. Your email address will not be used for any other purpose, and you can unsubscribe at any time.

Contact The School

Send a message to Let's Go with OOP:

Shortcuts

Share

Category