SlideShare a Scribd company logo
/******************Program 1 ***************
#include<iostream.h>
void display(char *s)
{
for(int x=0;s[x]>0;x++)
{
for(int y=0;y<=x;y++)
cout<<s[y];
cout<<endl;
}
}
void main()
{
char *t="LAND";
display(t);
}
*****************Program 2 ***************
#include<iostream.h>
int &max (int &x,int &y)
{
if(x>y)
return (x);
else
return (y);
}
void main()
{
clrscr();
int A=10,B=13;
max(A,B)=-1;
cout<<"A= "<<A<<"B= "<<B<<endl;
max(B,A)=7;
cout<<"A= "<<A<<"B= "<<B<<endl;
getch();
}
*****************Program 3 ***************
#include<iostream.h>
#include<conio.h>
int main()
{
clrscr();
char string[]="Pointers and strings";
cout<<*(&string[2])<<endl;
cout.write(string+5,15).put('n');
cout<<*(string+3)<<'n';
getch();
return 0;
}
/* // *****************Program 4 ***************
#include<iostream.h>
#include<conio.h>
int a=10;
void main()
{
void demo(int &,int,int*);
int a=20,b=5;
demo(::a,a,&b);
cout<<::a<<a<<b<<endl;
}
void demo(int &x,int y,int *z)
{
a+=x;
y*=a;
*z=a+y;
cout<<x<<y<<*z<<endl;
}
//*****************Program 5 ***************
#include<iostream.h>
#include<conio.h>
#include<string.h>
#include<ctype.h>
void main()
{
char *S="ObjeCT";
int L=strlen(S);
for(int C=0;C<L;C++)
if(islower(S[C]))
S[C]=toupper(S[C]);
else
if(C%2==0)
S[C]='E';
else
S[C]=tolower(S[C]);
cout<<"New message :"<<S;
getch();
}
//*****************Program 6 ***************
#include<iostream.h>
void Execute(int &x,int y=200)
{
int temp=x+y;
x+=temp;
if(y!=200)
cout<<temp<<" "<<x<<" "<<y<<endl;
}
void main()
{
int a=50,b=20;
Execute(b);
cout<<a<<" "<<b<<endl;
Execute(a,b);
cout<<a<<" "<<b<<endl;
}
//*****************Program 7 ***************
#include<iostream.h>
void print(char *p)
{
p="Pass";
cout<<"n Value is "<<p<<endl;
}
void main()
{
char *q="Best Of luck";
print(q);
cout<<"n New value is "<<q;
}
//*****************Program 8 ***************
#include<iostream.h>
#include<conio.h>
/*#include<string.h>
#include<ctype.h>
void main()
{
char *s="GOODLUCK";
for(int x=strlen(s)-1;x>0;x--)
{
for(int y=0;y<=x;y++) cout<<s[y];
cout<<endl;
}
}
//*****************Program 9 ***************
#include<iostream.h>
int a=3;
void demo(int x, int y,int &z)
{
a+=x+y;
z=a+y;
y+=x;
cout<<x<<" "<<y<<" "<<z<<endl;
}
void main()
{
int a=2,b=5;
demo(::a,a,b);
cout<<::a<<" " <<a<<" "<<b<<endl;
demo(::a,a,b);
}
//*****************Program 10 ***************
#include<iostream.h>
int max(int &x,int &y,int &z)
{
if(x>y &&y>z)
{
y++;
z++;
return x;
}
else
if(y>x)
return y;
else
return z;
}
void main()
{
int a=10,b=13,c=8;
a=max(a,b,c);
cout<<a<<b<<c<<endl;
b=max(a,b,c);
cout<<++a<<++b<<++c<<endl;
}
//*****************Program 11 ***************
#include<iostream.h>
#include<conio.h>
#include<string.h>
#include<ctype.h>
void main()
{
clrscr();
int a=32,*X=&a;
char ch=65,&cho=ch;
cho+=a;
*X+=ch;
cout<<a<<','<<ch<<endl;
}
//*****************Program 12 ***************
#include<iostream.h>
struct point
{
int x,y;
};
void show(point p)
{
cout<<p.x<<';'<<p.y<<endl;
}
void main()
{
point U={0,10},V,W;
V=U;
V.x+=0;
W=V;
U.y+=10;
U.x+=5;
W.x-=5;
show(U);
show(V);
show(W);
}
//************** Program 13 ***************
#include<iostream.h>
void main()
{
int x[]={10,20,30,40,50};
int *p,**q;
int *t;
p=x;
t=x+1;
q=&t;
cout<<*p<<','<<**q<<','<<*t++;
}
#include<iostream.h>
#include<conio.h>
#include<string.h>
#include<ctype.h>
class state
{
char *statename;
int size;
public:
state()
{
size=0;
statename=new char[size+1];
}
void display() { cout<<statename<<endl; }
state(char *s)
{
size=strlen(s);
statename=new char[size+1];
strcpy(statename,s);
}
void replace(state &a, state &b)
{ size=a.size+b.size;
delete statename;
statename=new char[size+1];
strcpy(statename,a.statename);
strcat(statename,b.statename);
}
};
void main()
{
char *temp="Delhi";
state state1(temp),state2("mumbai"),state3("Nagpur"),S1,S2;
S1.replace(state1,state2);
S2.replace(S1,state3);
S1.display();
S2.display();
}
*/
#include<iostream.h>
#include<conio.h>
#include<string.h>
#include<ctype.h>
void main()
{
clrscr();
long NUM=1234543;
int f=0,s=0;
do{
int rem=NUM%10;
if(rem%2==0)
f+=rem;
else
s+=rem;
NUM/=10;
}while(NUM>0);
cout<<f-s;
}
/************** OUTPUT Program 1 ***************
L
LA
LAN
LAND
************** OUTPUT Program 2 ***************
A= 10B= -1
A= 7B= -1
************** OUTPUT Program 3 ***************
i
ers and strings
n
************** OUTPUT Program 4 ***************
20400420
2020420
************** OUTPUT Program 5 ***************
New message :EBJEEt
************** OUTPUT Program 6 ***************
50 240
290 340 240
340 240
22
************** OUTPUT Program 7 ***************
Value is Pass
New value is Best Of luck
************** OUTPUT Program 8 ***************
GOODLUCK
GOODLUC
GOODLU
GOODL
GOOD
GOO
GO
************** OUTPUT Program 9 ***************
3 5 10
8 2 10
8 10 20
************** OUTPUT Program 10 ***************
13138
1499
************** OUTPUT Program 11 ***************
129,a
************** OUTPUT Program 12 ***************
5;20
0;10
-5;10
************** OUTPUT Program 13 ***************
10,30,20
************** OUTPUT Program 14 ***************
Delhimumbai
DelhimumbaiNagpur
************** OUTPUT Program 15 ***************
-2
*/

More Related Content

What's hot

20181020 advanced higher-order function
20181020 advanced higher-order function20181020 advanced higher-order function
20181020 advanced higher-order function
Chiwon Song
 
2016 gunma.web games-and-asm.js
2016 gunma.web games-and-asm.js2016 gunma.web games-and-asm.js
2016 gunma.web games-and-asm.js
Noritada Shimizu
 
Part2 from math import * from simpson import * k=1 def f(x): return (exp(-(x...
Part2 from math import * from simpson import *  k=1 def f(x): return (exp(-(x...Part2 from math import * from simpson import *  k=1 def f(x): return (exp(-(x...
Part2 from math import * from simpson import * k=1 def f(x): return (exp(-(x...
hwbloom25
 
20151224-games
20151224-games20151224-games
20151224-games
Noritada Shimizu
 
20180721 code defragment
20180721 code defragment20180721 code defragment
20180721 code defragment
Chiwon Song
 
Mozilla とブラウザゲーム
Mozilla とブラウザゲームMozilla とブラウザゲーム
Mozilla とブラウザゲーム
Noritada Shimizu
 
Shapes and calculate (area and contour) / C++ oop concept
Shapes and calculate (area and contour) / C++ oop conceptShapes and calculate (area and contour) / C++ oop concept
Shapes and calculate (area and contour) / C++ oop concept
kinan keshkeh
 
Cycle.js: Functional and Reactive
Cycle.js: Functional and ReactiveCycle.js: Functional and Reactive
Cycle.js: Functional and Reactive
Eugene Zharkov
 
Jarmo van de Seijp Shadbox ERC223
Jarmo van de Seijp Shadbox ERC223Jarmo van de Seijp Shadbox ERC223
Jarmo van de Seijp Shadbox ERC223
Jarmo van de Seijp
 
Shapes and calculate (area and contour) / C++ oop concept
Shapes and calculate (area and contour) / C++ oop conceptShapes and calculate (area and contour) / C++ oop concept
Shapes and calculate (area and contour) / C++ oop concept
kinan keshkeh
 
Elm: give it a try
Elm: give it a tryElm: give it a try
Elm: give it a try
Eugene Zharkov
 
Продвинутая отладка JavaScript с помощью Chrome Dev Tools
Продвинутая отладка JavaScript с помощью Chrome Dev ToolsПродвинутая отладка JavaScript с помощью Chrome Dev Tools
Продвинутая отладка JavaScript с помощью Chrome Dev Tools
FDConf
 
Go a crash course
Go   a crash courseGo   a crash course
Go a crash course
Eleanor McHugh
 
VLSI Sequential Circuits II
VLSI Sequential Circuits IIVLSI Sequential Circuits II
VLSI Sequential Circuits IIGouthaman V
 

What's hot (20)

20181020 advanced higher-order function
20181020 advanced higher-order function20181020 advanced higher-order function
20181020 advanced higher-order function
 
2016 gunma.web games-and-asm.js
2016 gunma.web games-and-asm.js2016 gunma.web games-and-asm.js
2016 gunma.web games-and-asm.js
 
C++ file
C++ fileC++ file
C++ file
 
Part2 from math import * from simpson import * k=1 def f(x): return (exp(-(x...
Part2 from math import * from simpson import *  k=1 def f(x): return (exp(-(x...Part2 from math import * from simpson import *  k=1 def f(x): return (exp(-(x...
Part2 from math import * from simpson import * k=1 def f(x): return (exp(-(x...
 
20151224-games
20151224-games20151224-games
20151224-games
 
20180721 code defragment
20180721 code defragment20180721 code defragment
20180721 code defragment
 
Mozilla とブラウザゲーム
Mozilla とブラウザゲームMozilla とブラウザゲーム
Mozilla とブラウザゲーム
 
Shapes and calculate (area and contour) / C++ oop concept
Shapes and calculate (area and contour) / C++ oop conceptShapes and calculate (area and contour) / C++ oop concept
Shapes and calculate (area and contour) / C++ oop concept
 
Oop lab report
Oop lab reportOop lab report
Oop lab report
 
Opp compile
Opp compileOpp compile
Opp compile
 
Cycle.js: Functional and Reactive
Cycle.js: Functional and ReactiveCycle.js: Functional and Reactive
Cycle.js: Functional and Reactive
 
Jarmo van de Seijp Shadbox ERC223
Jarmo van de Seijp Shadbox ERC223Jarmo van de Seijp Shadbox ERC223
Jarmo van de Seijp Shadbox ERC223
 
Shapes and calculate (area and contour) / C++ oop concept
Shapes and calculate (area and contour) / C++ oop conceptShapes and calculate (area and contour) / C++ oop concept
Shapes and calculate (area and contour) / C++ oop concept
 
Sbaw090519
Sbaw090519Sbaw090519
Sbaw090519
 
Code
CodeCode
Code
 
Elm: give it a try
Elm: give it a tryElm: give it a try
Elm: give it a try
 
Продвинутая отладка JavaScript с помощью Chrome Dev Tools
Продвинутая отладка JavaScript с помощью Chrome Dev ToolsПродвинутая отладка JavaScript с помощью Chrome Dev Tools
Продвинутая отладка JavaScript с помощью Chrome Dev Tools
 
Ee
EeEe
Ee
 
Go a crash course
Go   a crash courseGo   a crash course
Go a crash course
 
VLSI Sequential Circuits II
VLSI Sequential Circuits IIVLSI Sequential Circuits II
VLSI Sequential Circuits II
 

Similar to Program(Output)

Assignement c++
Assignement c++Assignement c++
Assignement c++
Syed Umair
 
c++ project on restaurant billing
c++ project on restaurant billing c++ project on restaurant billing
c++ project on restaurant billing
Swakriti Rathore
 
C++ Programming - 2nd Study
C++ Programming - 2nd StudyC++ Programming - 2nd Study
C++ Programming - 2nd Study
Chris Ohk
 
2014 computer science_question_paper
2014 computer science_question_paper2014 computer science_question_paper
2014 computer science_question_paper
vandna123
 
Project hotel on hotel management fo
Project  hotel on hotel management foProject  hotel on hotel management fo
Project hotel on hotel management fo
Sunny Singhania
 
C++ L05-Functions
C++ L05-FunctionsC++ L05-Functions
C++ L05-Functions
Mohammad Shaker
 
Assignement of programming & problem solving u.s ass.(1)
Assignement of programming & problem solving u.s ass.(1)Assignement of programming & problem solving u.s ass.(1)
Assignement of programming & problem solving u.s ass.(1)
Syed Umair
 
oodp elab.pdf
oodp elab.pdfoodp elab.pdf
oodp elab.pdf
SWATIKUMARIRA2111030
 
Blocks+gcd入門
Blocks+gcd入門Blocks+gcd入門
Blocks+gcd入門
領一 和泉田
 
Program of sorting using shell sort #include stdio.h #de.pdf
 Program of sorting using shell sort  #include stdio.h #de.pdf Program of sorting using shell sort  #include stdio.h #de.pdf
Program of sorting using shell sort #include stdio.h #de.pdf
anujmkt
 
operating system ubuntu,linux,MacProgram will work only if you g.pdf
operating system ubuntu,linux,MacProgram will work only if you g.pdfoperating system ubuntu,linux,MacProgram will work only if you g.pdf
operating system ubuntu,linux,MacProgram will work only if you g.pdf
aptcomputerzone
 
Assignement of c++
Assignement of c++Assignement of c++
Assignement of c++
Syed Umair
 
C# Assignmet Help
C# Assignmet HelpC# Assignmet Help
C# Assignmet Help
Programming Homework Help
 
寫程式?那些老師沒教的事 (Git 部分節錄)
寫程式?那些老師沒教的事 (Git 部分節錄)寫程式?那些老師沒教的事 (Git 部分節錄)
寫程式?那些老師沒教的事 (Git 部分節錄)
均民 戴
 
C++ Programming - 4th Study
C++ Programming - 4th StudyC++ Programming - 4th Study
C++ Programming - 4th Study
Chris Ohk
 
Implementing Software Machines in Go and C
Implementing Software Machines in Go and CImplementing Software Machines in Go and C
Implementing Software Machines in Go and C
Eleanor McHugh
 
#include iostream #include fstream #include iomanip #.pdf
 #include iostream #include fstream #include iomanip #.pdf #include iostream #include fstream #include iomanip #.pdf
#include iostream #include fstream #include iomanip #.pdf
KARTIKINDIA
 

Similar to Program(Output) (20)

Assignement c++
Assignement c++Assignement c++
Assignement c++
 
c++ project on restaurant billing
c++ project on restaurant billing c++ project on restaurant billing
c++ project on restaurant billing
 
C++ Programming - 2nd Study
C++ Programming - 2nd StudyC++ Programming - 2nd Study
C++ Programming - 2nd Study
 
2014 computer science_question_paper
2014 computer science_question_paper2014 computer science_question_paper
2014 computer science_question_paper
 
Project hotel on hotel management fo
Project  hotel on hotel management foProject  hotel on hotel management fo
Project hotel on hotel management fo
 
C++ L05-Functions
C++ L05-FunctionsC++ L05-Functions
C++ L05-Functions
 
Qno 1 (d)
Qno 1 (d)Qno 1 (d)
Qno 1 (d)
 
Assignement of programming & problem solving u.s ass.(1)
Assignement of programming & problem solving u.s ass.(1)Assignement of programming & problem solving u.s ass.(1)
Assignement of programming & problem solving u.s ass.(1)
 
oodp elab.pdf
oodp elab.pdfoodp elab.pdf
oodp elab.pdf
 
Cpp c++ 1
Cpp c++ 1Cpp c++ 1
Cpp c++ 1
 
Blocks+gcd入門
Blocks+gcd入門Blocks+gcd入門
Blocks+gcd入門
 
Program of sorting using shell sort #include stdio.h #de.pdf
 Program of sorting using shell sort  #include stdio.h #de.pdf Program of sorting using shell sort  #include stdio.h #de.pdf
Program of sorting using shell sort #include stdio.h #de.pdf
 
operating system ubuntu,linux,MacProgram will work only if you g.pdf
operating system ubuntu,linux,MacProgram will work only if you g.pdfoperating system ubuntu,linux,MacProgram will work only if you g.pdf
operating system ubuntu,linux,MacProgram will work only if you g.pdf
 
Assignement of c++
Assignement of c++Assignement of c++
Assignement of c++
 
C# Assignmet Help
C# Assignmet HelpC# Assignmet Help
C# Assignmet Help
 
寫程式?那些老師沒教的事 (Git 部分節錄)
寫程式?那些老師沒教的事 (Git 部分節錄)寫程式?那些老師沒教的事 (Git 部分節錄)
寫程式?那些老師沒教的事 (Git 部分節錄)
 
C++ Programming - 4th Study
C++ Programming - 4th StudyC++ Programming - 4th Study
C++ Programming - 4th Study
 
Pemrograman visual
Pemrograman visualPemrograman visual
Pemrograman visual
 
Implementing Software Machines in Go and C
Implementing Software Machines in Go and CImplementing Software Machines in Go and C
Implementing Software Machines in Go and C
 
#include iostream #include fstream #include iomanip #.pdf
 #include iostream #include fstream #include iomanip #.pdf #include iostream #include fstream #include iomanip #.pdf
#include iostream #include fstream #include iomanip #.pdf
 

Recently uploaded

Unit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdfUnit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Thiyagu K
 
Supporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptxSupporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptx
Jisc
 
A Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in EducationA Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in Education
Peter Windle
 
The Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptxThe Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptx
DhatriParmar
 
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
MysoreMuleSoftMeetup
 
1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx
JosvitaDsouza2
 
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXXPhrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
MIRIAMSALINAS13
 
The approach at University of Liverpool.pptx
The approach at University of Liverpool.pptxThe approach at University of Liverpool.pptx
The approach at University of Liverpool.pptx
Jisc
 
2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...
Sandy Millin
 
The geography of Taylor Swift - some ideas
The geography of Taylor Swift - some ideasThe geography of Taylor Swift - some ideas
The geography of Taylor Swift - some ideas
GeoBlogs
 
Digital Tools and AI for Teaching Learning and Research
Digital Tools and AI for Teaching Learning and ResearchDigital Tools and AI for Teaching Learning and Research
Digital Tools and AI for Teaching Learning and Research
Vikramjit Singh
 
Overview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with MechanismOverview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with Mechanism
DeeptiGupta154
 
Francesca Gottschalk - How can education support child empowerment.pptx
Francesca Gottschalk - How can education support child empowerment.pptxFrancesca Gottschalk - How can education support child empowerment.pptx
Francesca Gottschalk - How can education support child empowerment.pptx
EduSkills OECD
 
Model Attribute Check Company Auto Property
Model Attribute  Check Company Auto PropertyModel Attribute  Check Company Auto Property
Model Attribute Check Company Auto Property
Celine George
 
Polish students' mobility in the Czech Republic
Polish students' mobility in the Czech RepublicPolish students' mobility in the Czech Republic
Polish students' mobility in the Czech Republic
Anna Sz.
 
Operation Blue Star - Saka Neela Tara
Operation Blue Star   -  Saka Neela TaraOperation Blue Star   -  Saka Neela Tara
Operation Blue Star - Saka Neela Tara
Balvir Singh
 
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup   New Member Orientation and Q&A (May 2024).pdfWelcome to TechSoup   New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
TechSoup
 
How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17
Celine George
 
Home assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdfHome assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdf
Tamralipta Mahavidyalaya
 
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCECLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
BhavyaRajput3
 

Recently uploaded (20)

Unit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdfUnit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdf
 
Supporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptxSupporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptx
 
A Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in EducationA Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in Education
 
The Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptxThe Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptx
 
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
 
1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx
 
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXXPhrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
 
The approach at University of Liverpool.pptx
The approach at University of Liverpool.pptxThe approach at University of Liverpool.pptx
The approach at University of Liverpool.pptx
 
2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...
 
The geography of Taylor Swift - some ideas
The geography of Taylor Swift - some ideasThe geography of Taylor Swift - some ideas
The geography of Taylor Swift - some ideas
 
Digital Tools and AI for Teaching Learning and Research
Digital Tools and AI for Teaching Learning and ResearchDigital Tools and AI for Teaching Learning and Research
Digital Tools and AI for Teaching Learning and Research
 
Overview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with MechanismOverview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with Mechanism
 
Francesca Gottschalk - How can education support child empowerment.pptx
Francesca Gottschalk - How can education support child empowerment.pptxFrancesca Gottschalk - How can education support child empowerment.pptx
Francesca Gottschalk - How can education support child empowerment.pptx
 
Model Attribute Check Company Auto Property
Model Attribute  Check Company Auto PropertyModel Attribute  Check Company Auto Property
Model Attribute Check Company Auto Property
 
Polish students' mobility in the Czech Republic
Polish students' mobility in the Czech RepublicPolish students' mobility in the Czech Republic
Polish students' mobility in the Czech Republic
 
Operation Blue Star - Saka Neela Tara
Operation Blue Star   -  Saka Neela TaraOperation Blue Star   -  Saka Neela Tara
Operation Blue Star - Saka Neela Tara
 
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup   New Member Orientation and Q&A (May 2024).pdfWelcome to TechSoup   New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
 
How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17
 
Home assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdfHome assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdf
 
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCECLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
 

Program(Output)

  • 1. /******************Program 1 *************** #include<iostream.h> void display(char *s) { for(int x=0;s[x]>0;x++) { for(int y=0;y<=x;y++) cout<<s[y]; cout<<endl; } } void main() { char *t="LAND"; display(t); } *****************Program 2 *************** #include<iostream.h> int &max (int &x,int &y) { if(x>y) return (x); else return (y); } void main()
  • 2. { clrscr(); int A=10,B=13; max(A,B)=-1; cout<<"A= "<<A<<"B= "<<B<<endl; max(B,A)=7; cout<<"A= "<<A<<"B= "<<B<<endl; getch(); } *****************Program 3 *************** #include<iostream.h> #include<conio.h> int main() { clrscr(); char string[]="Pointers and strings"; cout<<*(&string[2])<<endl; cout.write(string+5,15).put('n'); cout<<*(string+3)<<'n'; getch(); return 0; } /* // *****************Program 4 *************** #include<iostream.h> #include<conio.h> int a=10; void main()
  • 3. { void demo(int &,int,int*); int a=20,b=5; demo(::a,a,&b); cout<<::a<<a<<b<<endl; } void demo(int &x,int y,int *z) { a+=x; y*=a; *z=a+y; cout<<x<<y<<*z<<endl; } //*****************Program 5 *************** #include<iostream.h> #include<conio.h> #include<string.h> #include<ctype.h> void main() { char *S="ObjeCT"; int L=strlen(S); for(int C=0;C<L;C++) if(islower(S[C])) S[C]=toupper(S[C]);
  • 4. else if(C%2==0) S[C]='E'; else S[C]=tolower(S[C]); cout<<"New message :"<<S; getch(); } //*****************Program 6 *************** #include<iostream.h> void Execute(int &x,int y=200) { int temp=x+y; x+=temp; if(y!=200) cout<<temp<<" "<<x<<" "<<y<<endl; } void main() { int a=50,b=20; Execute(b); cout<<a<<" "<<b<<endl; Execute(a,b); cout<<a<<" "<<b<<endl; }
  • 5. //*****************Program 7 *************** #include<iostream.h> void print(char *p) { p="Pass"; cout<<"n Value is "<<p<<endl; } void main() { char *q="Best Of luck"; print(q); cout<<"n New value is "<<q; } //*****************Program 8 *************** #include<iostream.h> #include<conio.h> /*#include<string.h> #include<ctype.h> void main() { char *s="GOODLUCK"; for(int x=strlen(s)-1;x>0;x--) { for(int y=0;y<=x;y++) cout<<s[y]; cout<<endl;
  • 6. } } //*****************Program 9 *************** #include<iostream.h> int a=3; void demo(int x, int y,int &z) { a+=x+y; z=a+y; y+=x; cout<<x<<" "<<y<<" "<<z<<endl; } void main() { int a=2,b=5; demo(::a,a,b); cout<<::a<<" " <<a<<" "<<b<<endl; demo(::a,a,b); } //*****************Program 10 *************** #include<iostream.h> int max(int &x,int &y,int &z) { if(x>y &&y>z) {
  • 7. y++; z++; return x; } else if(y>x) return y; else return z; } void main() { int a=10,b=13,c=8; a=max(a,b,c); cout<<a<<b<<c<<endl; b=max(a,b,c); cout<<++a<<++b<<++c<<endl; } //*****************Program 11 *************** #include<iostream.h> #include<conio.h> #include<string.h> #include<ctype.h> void main() { clrscr(); int a=32,*X=&a;
  • 8. char ch=65,&cho=ch; cho+=a; *X+=ch; cout<<a<<','<<ch<<endl; } //*****************Program 12 *************** #include<iostream.h> struct point { int x,y; }; void show(point p) { cout<<p.x<<';'<<p.y<<endl; } void main() { point U={0,10},V,W; V=U; V.x+=0; W=V; U.y+=10; U.x+=5; W.x-=5; show(U); show(V);
  • 9. show(W); } //************** Program 13 *************** #include<iostream.h> void main() { int x[]={10,20,30,40,50}; int *p,**q; int *t; p=x; t=x+1; q=&t; cout<<*p<<','<<**q<<','<<*t++; } #include<iostream.h> #include<conio.h> #include<string.h> #include<ctype.h> class state { char *statename; int size; public: state()
  • 10. { size=0; statename=new char[size+1]; } void display() { cout<<statename<<endl; } state(char *s) { size=strlen(s); statename=new char[size+1]; strcpy(statename,s); } void replace(state &a, state &b) { size=a.size+b.size; delete statename; statename=new char[size+1]; strcpy(statename,a.statename); strcat(statename,b.statename); } }; void main() { char *temp="Delhi"; state state1(temp),state2("mumbai"),state3("Nagpur"),S1,S2; S1.replace(state1,state2); S2.replace(S1,state3); S1.display(); S2.display();
  • 11. } */ #include<iostream.h> #include<conio.h> #include<string.h> #include<ctype.h> void main() { clrscr(); long NUM=1234543; int f=0,s=0; do{ int rem=NUM%10; if(rem%2==0) f+=rem; else s+=rem; NUM/=10; }while(NUM>0); cout<<f-s; } /************** OUTPUT Program 1 *************** L LA LAN
  • 12. LAND ************** OUTPUT Program 2 *************** A= 10B= -1 A= 7B= -1 ************** OUTPUT Program 3 *************** i ers and strings n ************** OUTPUT Program 4 *************** 20400420 2020420 ************** OUTPUT Program 5 *************** New message :EBJEEt ************** OUTPUT Program 6 *************** 50 240 290 340 240 340 240 22 ************** OUTPUT Program 7 *************** Value is Pass New value is Best Of luck ************** OUTPUT Program 8 *************** GOODLUCK GOODLUC GOODLU
  • 13. GOODL GOOD GOO GO ************** OUTPUT Program 9 *************** 3 5 10 8 2 10 8 10 20 ************** OUTPUT Program 10 *************** 13138 1499 ************** OUTPUT Program 11 *************** 129,a ************** OUTPUT Program 12 *************** 5;20 0;10 -5;10 ************** OUTPUT Program 13 *************** 10,30,20 ************** OUTPUT Program 14 *************** Delhimumbai DelhimumbaiNagpur
  • 14. ************** OUTPUT Program 15 *************** -2 */