0% found this document useful (0 votes)
62 views

C Assignment 4

1. The document describes an algorithm to classify a character as a vowel or consonant. 2. It takes a character as input, checks if it is a vowel ('a', 'e', 'i', 'o', or 'u'), and prints that the character is a vowel. Otherwise, it prints that the character is a consonant. 3. The steps declare a character variable, get character input, check for vowels, and print the output.

Uploaded by

Dipta Karar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
62 views

C Assignment 4

1. The document describes an algorithm to classify a character as a vowel or consonant. 2. It takes a character as input, checks if it is a vowel ('a', 'e', 'i', 'o', or 'u'), and prints that the character is a vowel. Otherwise, it prints that the character is a consonant. 3. The steps declare a character variable, get character input, check for vowels, and print the output.

Uploaded by

Dipta Karar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

INSTITUTE OF RING&MANAGEMENT

Poge No. 18
Assign meht 4
incLuole (Stodio.hl
nt mairu O
S float amt, tay, tamE
Dstntf En bes eloeste bill ambint= "
stant C7of \amt);
f (amt &00) thon 80o, So no hed
SDRnt fC BUL amBuntis Jess
to Pay toy. \n);
PstntfTo tal ameunt Posyolle is = Rs%f\n

elseP ant)=Roo & amt 120oo


Stay =amt O.l; to ef In ) bax);
Pointf Toy nee pay
tamt- amt t tax
7Total Payable
ambin+ TS =R %f In'y
Pint FC
tamt);
else Pf (amE>= |20o ant (200o)
Eo amt O.15";
PaintfTay need to Poy %f In'y tyo;
tamt amt+b;
Pin-fCTotal Paualle ambnt is Re e
n,tamt)} {
else
toyeamt * 0:22-
DCame No99E Paul Roll alo05

Section: Year: St
NSTITUTE OF ENGINEERING &MANAGEMENT Page No. 1
DntFC7Tay ned toPay = %f In'y tay);
tomt mt +tay
Dsint fCTobal Poyalle ambunt i
=
Rs %f In
t amt);
etiln 0

bll ampun 70
Test Cale1Ente eloete
amtant is Jess Ekan Soo, So no
bil
need to Pouy tax
780o
Total ampnt Payable is Rs
=

lo0o
2-En.tes elecbie bL ambtun
Test Case /0o
Tay heeo to Poy
is Rg ll0o
Total Pauable. am@unt
=

RallOa 1as
Kae NolsPt Paul
ITUTEOF ENGINEERING &MANAGEMENT Page No. 20

3 TART
step1i-
2elate va iahJa tanmt ot Lyre
Cp 2 amt, tay,
loat
Arep 3-,nll-at2, amt hom UceS
J amt <2oo
4pe4
Di pla tey pajel i NIL aAd tpal amt
Poyalo
elee amt=2oo and amt 200
tay amt x O.|
tamtamtt bx
OISptauTax Aeed bo pay and tof amburt
paable 2000
ese a m t = 1200 nd cimt
tax-am *O. 15
tamt aamtt
to pay qtofal
amBund
Dicpay Tey necl
Poable
elne
tx-aamt * O-22

am amb
tay
DiployTaynd o pay ano toal ambui
Pauy able.
step 6 ToP

RallNa Jo5
Name:
Name: Na9itPaul
Year: 1St
Section
TTE OF ENGINEERING &MANAGEMENT
TITUTE
2.1
Page No. nosit

Pho a 2-
i n e l
o
ht mainO

c clhat ala smt,ghacle_Commi,


Pint-fEntro C. tamt
f Ent Salo ambunt ;

Dshtf CEnte ghaol-


SGnf Cf',
fSaleamE 2O00
SComm= Saleomt 0-2.35;
Phtnt fC CommissiGru e Rs.f \n', Cemmi) ;
tamt-Sale amt+Commi
hnteTobal Poyable amtunt Ra.7f n'g tomb;

he 4leamt>=2000 d gpaey k gsole <-


Comm-Sale amt o.23
PeintFCommjstibru - Rs.f In'ommi)
tamt-Sale_amt t Conmi;
Psintf Total Payablo amta- R-7of \n", tant)

else 4(Saleamt 1200o & 9acle>s)


Comm= Salo am E X 0-224;
Pi (Cemm'scfer R,%F In", amm)j
tamt-Soleamt Commi
Tala 1o5
Vene NasiE Pau
N S T I

u &MANAGEMENT
2.2
To tal Page No. ar

Paujabo_amun- Re. f In'y tanty


Comm==
Salo_ant *D« 218
betf"Commi sCi6nu
Rs-%f \', Commi);=

famt Salo amt


omm ;
C5ntlota Payahe antunt- Rs. antj
7f \n,

OPuto- Ente Sale ameun= 1300o


En te 9aolo = 4
CommiSCiOn =
Rs. 299 o.00
To tal auallo ambunt- Rs. 15990.0o

Tolla. 1o5
Xame
Xame Nal9it Paul
TUTEOFENGINEERING&MANAC Page No. .
23 .

Pah 26-(Alqo9ithm)
ep 3 TART

2Declahe Vajoble Sle at, 2hade, Cenm


ep2
tamt o tyre oaf
p 3 i p a l z e bloamt and 9ado rem D
0D Lt-it balo amE= 1200 0 and godo>5
Cemmi= 5alcamt }K o. 235
amt bale amt+ Commi
DESploCemmicsion anel Tokal ambut Pcyabe
elgeitsale ant>=12 000 aed gicde.> 3 andad
Comni= bale amt X 0.23
tamt Saleamtt Cemmi
Cem C i o n anel Totel ambun Payabe
DEplouy
>5
ele a l oam</2000 ano 2odo
Cemmi = Sale_amt*0-2.4

tamb Salo amt+ Commj


ament payabe
CemmiSien and Tofl
Dispo
else
Cempi= aleamt O21S
tamt aloemt + Cemm
Dis plo Cemmisien Qnel Tofal an punt- Payablo-

8tep5-TOP

RollOa: 1o5
ome:NaRa,o u
anUTE OF ENGINEERING&MANAGI
STITUTE

Page No. 24
Pooham3

Int main ()
int a
f(EnLe the numbes -
);
tanfd,4;
( a %2 =: o)
pstnC The numbeh ic Even In);
ble
DstnfC Thenumber is Ocld In");

OutPu-Entes the humbes. =lo2


numbe is Even
The
OF ENGINEERN
ING&MAINAGEMENT
ENGINDERING &
ST1TUTEOFI
MANAGEMENT PageNo..25
Aam 58-MgoitK
ep1 TART
h2-eelaho. yaijable a bt Eype inkae3
3 Titi2e a rem USe
b40 %2 ==o
Displa the_numbe is even
else
Dsplou te_nunbe i oold

tep 5 TOP
26
INSTHTUTE OF ENGINEERING &MANAGEMENT Page No. on

Pho Sam 4
telude <Stdiok
9nt main C)
Cha ch
Dsintf C"Entes. the phaber-');
Seanf C%e", kch;
'E' It eh--1' || cha-Co
C h = A | ch- =
Ch== Ce'
Il Ch-= I | Ch=- °a ||
1'Il eh== 0 || eh== Cy')
Ch is Vowel. In");
SPin-"The alphabe-

else alphabek is CenSonant In);|


FThe
patntF
ehin o
Mphabe E
Entes tiee
Dutputo- vowel.
alphabe- is
The
sATUIEO F
STTUTE FENGINEERING &MANAGEMENT
ENG
Page No.
2-7
*raepaupierranrn

o40- TART
e

23-Deelohe Vehble. eh of type Chaecfs-|


2 D e e l a s e

z0Tnitze. Ch hm Uce.
- i Ch-= oA eh=- E' Chr=
ePh Ch==Cu s . ch- -a 0 0s Ch==E
Ch

OFs ploay t s vowel.


else
JExplauy it Cen SenQnt
tep5-3ToP

Roll No.
ame:
Year:

You might also like