Python Projects for Beginners a ten-Week Bootcamp Approach to Python Programming



Download 2,61 Mb.
bet24/200
Sana20.06.2022
Hajmi2,61 Mb.
#681748
1   ...   20   21   22   23   24   25   26   27   ...   200
Bog'liq
Python Projects for Beginners A Ten Week Bootcamp Approach to Python

CHALLENGE QUESTION
In programming, we have a concept called “algorithms.” An algorithm is simply just a set of steps. Whether you know it or not, you’ve used algorithms throughout your life. A common algorithm is a recipe that you follow to make food.
To think like a developer, you must begin to understand how a computer reads code. A computer is only as smart as the program that it’s supposed to execute. This means that even the smartest computers can fail if the steps aren’t correct. Let’s use a recipe to bake a cake, for instance. If we miss a single step or leave the cake in the oven for too long, then we fail, as would a computer that is missing a crucial step.
Now, I’d like you to think about the steps for making a peanut butter and jelly sandwich. Write down your steps on a piece of paper. Try to think like a computer when you write them out and understand that you need to be as precise as possible. The answer will be at the end of this chapter.

Monday: Comments and Basic Data Types
Today marks your first lesson of the Python language! The two concepts taught today will help build that foundation that we’re striving for. To follow along with the content for today, let’s open up Jupyter Notebook from our “python_bootcamp” folder. If needed, go back to last week’s lesson on how to open up Jupyter Notebook. Once it’s open, create a new file, and rename it to “Week_02.” Next, make the first cell markdown, with the following code:

# Comments & Basic Data Types

What Are Comments and Why Use Them?
Comments are like notes that you leave behind, either for yourself or someone else to read. They are not read in by the interpreter, meaning that you can write whatever you want, and the computer will ignore it. A good comment will be short, easy to read, and to the point. Putting a comment on every line is tedious, but not putting any comments at all is bad practice. As you program, you’ll begin to understand what that happy medium looks like.
When you begin to write larger programs, you’ll want to leave notes for yourself. Too often have I created a program, stopped working on it for three weeks, and when I came back, I forget what I was working on. Leaving comments isn’t only good for yourself but also for others who will read your code. Think of comments as breadcrumbs that help you understand what’s going on.

Download 2,61 Mb.

Do'stlaringiz bilan baham:
1   ...   20   21   22   23   24   25   26   27   ...   200




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2024
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish