Sample Year 8 Python Project

Download as pdf or txt
Download as pdf or txt
You are on page 1of 7

CAMB RIDGE HIGH SCHO OL

ABU DHABI

PROJECT ON
BUSINES S

p,ythonT"' 1

SUBMITTED BY : AMBER VIEGAS

YEARGROUP :~2

PROJECT GUIDED BY : Dr.Frithi Herbert


Thesis
My prolect has three maior programs:

Profit or Loss
Employment details
Customer service

What Is profit?

Profit is financial gain; the difference between the amoun


t spent and amount earned.
What Is loss?

Loss is the amount of money that has become a debt due


to insufficient earnings.
What Is profit or loss and how Is It related to programming
?
Profit or loss is a program that is used to determine whethe
r the seller has gained a profit or
incurred loss as well as efficiently calculate the profit or loss
of a company or any business
organization.

What are employment details?

Employment details is information on employees.

How are employment details useful?

When employing a new member of staff, they are asked


to answer a questionnaire which will then
be saved as their details in the system and can be review
ed or updated at any time.
What is customer service?

Customer service is ensuring customer satisfaction.

Why is customer service helpful?

If a customer has a suggestion, enquiry or complain they


can contact customer service who will
guide them

'II
I
Introduction
for multiple programming purposes. First Released in
Python is a interpreted high level programming language used
phy which
1991, named after Monty Python and created by Guido van Rossum, Python has a design philoso
emphasizes on code readability, notably using white space.
testing microchips at intel, to powering lnstagram, to
It'~ u~ed by thousands of people to accomplish things from
buildmg games with the PYGame library.

Why is Python named python?


was reading the published scripts of 'Monty Python's
W~en ~e began implementing Python, Guido van Rossum
a name which was short, unique and slightly mysterious
Flymg Circus', a BBC comedy from the 1970s. Guido wanted
and so he chose Python.

Why is Python so popular?


it a great choice for beginners and experts alike. It's
Python is versatile, easy to use and understand making
waste time understanding the mysterious syntax that
readability allows you to think like a programmer and not
other programming languages require.

Applications for Python with examples

Web and Interne t Development:

Frameworks
Micro-frameworks
Advanced content management systems
HTML
XML
Email processing

Scientific and Numeric:

, and engine ering.


SciPy is a collect ion of packages for mathematics, science
Pandas is a data analysis and modeli ng library.
editing and record ing of a work session,
!Pytho n is a power ful interac tive shell that features easy
and suppo rts visualizations and parallel compu ting.
scienti fic compu ting, runnin g bootca mps and
The Softwa re Carpen try Course teaches basic skills for
provid ing open-access teachin g materials.

Deskto p GUls:

wxWid gets
Kivy
Platfor m toolkit s

Software Development:

Scons for build control


ations and testing
Buildbot and Apache Gump for automated continuous complic
Roundup or Trac for bug tracking and project management

Business:
of business applications.
Odoo is an all in one management software offering a range
Tryton is a three tier general purpose high level platform
~•Pore "4ce"""' . c."
• "4c,"""'•""<e"""'•-II
-P::-1.nt "Cur~nt dat:e and t ~ u.nnq -''tr ~ o d of da:enme obJec •
P!'l~t :st::: (Qev) th

The first part of the program is to show the date and


time.
ll:l!Serna:ne = :::aw-_inpat("Login: >> ")
ll:I.Se:tl & "~r"
l.f a:s ~ l :

p::-i:'lt "Acee.,., grant:ed"


else:
p::-1.nc "Ace~., deru.ed"

The second part requires a login to gain access.


This is a choice question, you are supposed to choose
one of the options available.
l. f :r"""A:
p::-int "En~er co.,t price:"
c:p s U!.pUt (}
p::-inc "Enter .,e111.ng price:"
.5P --= .u:puc; ()
1f cp-,5p:
p=1nt "No Profit No Lo_,., ..
elif cp>~=
p=int "You are running a lo_,., ..
la!!!!--= cp-.511'
print "Incur~d lo.,.,= ",loss
el.,e:
p=ir.c "You are running a profit"
p.rotic s sp-cp
p=int "Gained profit• ",profi~

If A is has been selected, the following program will run.


el if t- B :
of employee"
Pr in t "E nt er name
pu t ()
em.,1oyee • raw _in
P= in t "E nt er HRA: 11

hr a• in pu t()
P:= int "E nt er DA :"
da • in pu t()
P~ in t "E nt er PF :"
pf • in pu t()
Sa lar y: "
P= in t "E nt er Ba sic t()
ba s1 c sa la ry •in pu
s1c sa lar y+ da -p t
to ta l-s al ar ya hra+ba ,to ta l_ sa la ry
:"
p~ in t-" To ta l sa la ry

ed, the following program will run.


If B is select
el1 .f f-- C:
su gg eS c? "
rv ice ? Would yo u lik e to co mp lai n or
be of se
pr in t "How ca n we
C • "c om pla in"
S- = "s ug ge st"
ra w_in pu t () r"
be low on th e ma tte
P= ~n t "P lea se ty pe
ra w_ in pu t ()
in to it"
p= ir. t "W e'l l lo ok

lected, the following program will run.


If C is se
Curr ent date and time usinq str meth od
!201a-os-14• 11:07:42.1osooo o~ date time obje ct:
....,.er
gram n•
These 2 lines will always come as an outpu t no onse from the pro
matte r what. It needs no resp
to work .

Outp ut 1

If the progr amm er has logged correctly, the follow


ing will be displayed:
Loqi.n : >> Amber
Acce ss qrant ed
Pi.ck what you wo?ld like to choos e,
Eq. A, B or C.

A - Pro~i .t & Loss Calcu lation


B - Emplo yment Deta ils
C - Stude nt Deta ils
Your Choic e:

Now it's time to make a choice.

If A is selected:

Or
Your Choi ce: A
Ente r cost pric e:
76
Ente r se1l inq pric e:
56
You are runn ing a loss
Incu rred los s• 20

Ifs is selec ted:

Your Choi ce: B


Ente r name o~ empl oyee
Sa.Ill
Ente r HRA:
5600 0
Ente r DA:
4000 0
Ente r PF:
7800 0
Ente r Basi c Sala ry:
6000 0
Tota l sala ry: 7800 0

If c is selected:
Your Choic e: C
How can web- 0 ~• servi ce? Would you like to comp lain or sugge st?
Comp l.ain
Pl.eas e type bel.ow on the matte r
There was an issue conce rning the bill
We'll . look into it
Or

Your Choi ce: C


sugge st?
How can we be of servi ce? Would you like to comp lain or
Suqq est
Pleas e type below on the matte r
You miqh t make more money if you have more o~fer s
.
We'll . look into it

Outpu t 2

If the login is incorrect:

Logi n:>> Nico le


Acce ss denie d

You might also like