Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions submissions/2019/ASC.CPP
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#include<iostream.h>
#include<conio.h>
#include<ctype.h>
void main()
{clrscr();
int i;
char ch;
cout<<"Please put the value of a character"<<endl;
cin>>ch;
i=ch;
cout<<"The ASCII valur of the entered character is "<<i<<endl;
getch();
}
34 changes: 34 additions & 0 deletions submissions/2019/BUB_FUN.CPP
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
#include<iostream.h>
#include<conio.h>
void sort(int a[],int x);
void main()

{clrscr();
int n=5,i,arr[10];
for(i=0;i<n;i++)
{cin>>arr[i];
}
sort(arr,n);
getch();
}

void sort(int a[],int x)
{int i,j,temp=0;

for(i=0;i<x;i++)
{
for(j=0;j<(x-1)-i;j++)
{ if(a[j]>a[j+1])
{
temp=a[j];
a[j]=a[j+1];
a[j+1]=temp;
}
}
}
for(i=0;i<x;i++)
{cout<<a[i]<<endl;
}

}

14 changes: 14 additions & 0 deletions submissions/2019/IF_AND_E.CPP
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#include<iostream.h>
#include<ctype.h>
#include<conio.h>
void main()
{clrscr();
int i,j;
cout<<"Please put the numbers for the comparison "<<endl;
cin>>i>>j;
if(i<'j')
{cout<<"The larger number is "<<j<<endl;}
else
{cout<<"the larger number is "<<i<<endl;}
getch();
}