0% found this document useful (0 votes)
2K views16 pages

C++ Programs Computer Science 12th HSC

Cpp programs HSC

Uploaded by

Rushikesh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
0% found this document useful (0 votes)
2K views16 pages

C++ Programs Computer Science 12th HSC

Cpp programs HSC

Uploaded by

Rushikesh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
You are on page 1/ 16
Experiment No:: Title:- C++ Program By Using array And Pointer. includeciostream.h> #include void main() { int a[10],p; int top,bot,mid,i; clrser( cout<<"Enter 10 Nos. in Ascending order :\n"; for(iz0;i<10;i++) cin>>ali); } top=0,bot=9; cout<<"\n Enter the number that you want to search:\n"; cin>>4 mid=(top+bot)/2; while((top<=bot)&&(a{mid] !=p)) fi if{p finclude void swapifloat &x,float &y) { float temp; temp=x; ey; yetemp; } void main() { void swapifloat & float&); float 1,92; elrser(); cout<<"Enter two number nl and a2"; cin>>ndo>n2; swap(n.n2), cout<<"\n Swapping of two number is:\t" class ratio 4 n> public: void assign (int, int); double convert (); void invert (); void print(); private: int num, den; de void main() ( elrser()i ratio r; r.assign (22,7); cout<<"re"; reprint (); cout<<"="< #inciude class citcie f private: float xy.F5 float areai,circums; publi void assign(); void area(); vold circumference}; void print(); i void circle:assignt) { coute<"Enter the x and y co-ordinate of circle :\n"; ein>>10>y; ‘cout<<"Enter The radius of circl cin>>r; } void circle:: area() void circle:: circumference() { areal: + void circle:: print() { cout<<"x and ¥ coordinate of the circle:">alil; } top=0,bot=9; cout<<"\n Enter the number that you want to search:\n"; cin>>p; {top+bot)/2; while((top<=bot)&&(a{mig}!=p) { if{p #include class complex { float x,yi public: complex () { } complex (float real,float img) { x=real; mg complex operator+ (complex c) ( complex t; CemeXtC. x7 t.ysyte.ys return (t); ) void comple: { display (void) cout< ¥include class student ( int rollno; public: void getno(int a) { rollno=a; } void putno(void) ( cout<<"\nRoll no=:"<print(); student y("tom",101); pty; intd)s OF - Experiment No:10 Practice:- Design a simple webpage with text.

Mudhoji High School & Junior College

CS Dept
stable borderss align=center> <My School Image

To,
Mudhoji High School & Jr College,Phaltan.


Ta Mashed Mig Svkoot A J+ Codrge, Penton, ‘Tab Peates Dior Setere => te tae enemas eecatseme enna ~~ Experiment NOLL pmesissessone Practice Design a simple web page with graphics and text head? wtitle> C$ Depte/title>



“scenter>simg src="E:\2022-23\Computer Science 2022\Practicle PROGRAM Demo\12 CS\Lipg">
cth colspan=3> TEMPERATURE ACCOUNTé/th> ths Citys/th> s ‘sth> Mumbaic/th> sth> 216/th> sth 40 str aligns"center"> sth> 18¢/th> s/table> chr size=5 color=blue> Output: Bate ee Practice:-Write VB Script program with If-else statement <% @ language="vbscript” 96> <% dim ab for a=1 to 20 step 1 if(a mod 2=0) then response.write(a) response.write("
") endif next % Experiment No:12 -- ——— Output: x aN yee 34 16 18 20

You might also like

Maxe/th> the Ming/th> fo ‘
37 Punes/th> sth> 32