Pada posting sebelumnya sudah dicontohkan soal pemrograman dalam bahasa Python. Kali ini, akan ditampilkan lagi contoh berikutnya.
Soal:
Buatlah program Python untuk menampilkan pola segitiga siku-siku menggunakan for … in.
Jawab:
Pola 1
* * * * * * * * * * * * * * * * * * * * *
Jawab:
| siku_siku_1.py |
tinggi = 6
for baris in range(0, tinggi):
for kolom in range(0, tinggi-baris):
print("*", end=" ")
print("")
|
Pola 2
* * * * * * * * * * * * * * * * * * * * *
Jawab:
| siku_siku_2.py |
tinggi = 6
for baris in range(0, tinggi):
for kolom in range(0, baris+1):
print("*", end=" ")
print("")
|
Pola 3
*
* *
* * *
* * * *
* * * * *
* * * * * *
Jawab:
| siku_siku_3.py |
tinggi = 6
for baris in range(0, tinggi):
for kolom in range(1, tinggi-baris):
print(" ", end=" ")
for bintang in range(0, baris+1):
print("*", end=" ")
print("")
|
Demikian contoh pola segitiga dalam pemrograman Python. Semoga bermanfaat.
The other day, while I was at work, my sister stole my apple ipad and tested to
see if it can survive a thirty foot drop, just
so she can be a youtube sensation. My apple ipad is now broken and she has 83 views.
I know this is completely off topic but I had to
share it with someone!
Amazing! Its actually remarkable article, I have got much clear idea about from this paragraph.
Yes! Finally something about https://myemotion.faith/wiki/Is_Minecraft_Server_Worth_To_You.
With havin so much content do you ever run into any problems of plagorism or copyright infringement?
My site has a lot of unique content I’ve either authored myself or outsourced but it seems a lot of
it is popping it up all over the internet without my permission. Do you know any methods to help stop content from being stolen? I’d certainly appreciate it.
Hello to all, how is everything, I think every one is getting more from this site, and your views are fastidious
in support of new viewers.
Why viewers still make use of to read news
papers when in this technological globe the whole thing is
existing on net?
Today, I went to the beachfront with my children. I found a
sea shell and gave it to my 4 year old daughter and
said “You can hear the ocean if you put this to your ear.” She put the shell
to her ear and screamed. There was a hermit crab inside and it pinched her ear.
She never wants to go back! LoL I know this is totally off topic but
I had to tell someone!
Its like you read my mind! You seem to know so much about this, like you wrote the book
in it or something. I think that you could
do with a few pics to drive the message home a bit, but other than that, this is excellent blog.
An excellent read. I’ll certainly be back.
Hi, There’s no doubt that your blog could possibly be having browser compatibility issues.
When I look at your blog in Safari, it looks fine however, if opening in IE,
it’s got some overlapping issues. I simply wanted to give you a quick heads up!
Apart from that, fantastic site!
Keep on writing, great job!
I’m amazed, I have to admit. Rarely do I come across a
blog that’s both educative and amusing, and without a doubt,
you have hit the nail on the head. The issue is something not enough folks are speaking intelligently about.
I am very happy that I found this in my hunt for something regarding
this.
I do not know if it’s just me or if everyone else experiencing issues with
your blog. It appears like some of the text within your content
are running off the screen. Can somebody else please provide feedback and
let me know if this is happening to them too? This could be a problem
with my internet browser because I’ve had this happen before.
Kudos
Very nice post. I just stumbled upon your weblog and wished
to say that I have truly enjoyed browsing your blog
posts. After all I’ll be subscribing to your feed and I hope you write again very
soon!
I just like the helpful info you provide on your articles.
I will bookmark your weblog and check again here regularly.
I am relatively sure I’ll be informed lots of new
stuff right here! Good luck for the next!
Link exchange is nothing else but it is simply placing
the other person’s weblog link on your page at proper place and other person will also do same in favor of you.
Its not my first time to visit this web site, i am browsing this web page dailly and obtain good information from here all the time.
Very shortly this site will be famous among all blogging users,
due to it’s fastidious content
Hmm is anyone else having problems with the images on this blog
loading? I’m trying to figure out if its a problem on my end or if it’s the blog.
Any responses would be greatly appreciated.
This is my first time visit at here and i am truly
impressed to read everthing at alone place.
This paragraph will assist the internet people for setting up new
web site or even a blog from start to end.
This post is in fact a nice one it helps new net visitors, who are wishing in favor of blogging.
Hmm is anyone else having problems with the images on this blog loading?
I’m trying to find out if its a problem on my end or if it’s the blog.
Any responses would be greatly appreciated.
Appreciate this post. Let me try it out.
Good article. I’m experiencing a few of these issues as well..
Hello fantastic blog! Does running a blog like this take a lot of work?
I have absolutely no knowledge of programming however I was hoping to start my own blog
soon. Anyhow, should you have any suggestions or tips for new blog owners please share.
I know this is off topic nevertheless I just wanted to ask.
Cheers!
Excellent post. I will be facing many of these issues as well..
ютуб
It’s wonderful that you are getting ideas from this article as well as from
our discussion made at this place.
I am regular visitor, how are you everybody?
This post posted at this site is truly nice.
Incredible points. Outstanding arguments. Keep up the amazing spirit.
Hello there, You’ve done a fantastic job. I’ll definitely digg it and personally recommend to my friends.
I’m sure they will be benefited from this site.
Hi, its good article concerning media print, we all be familiar with media is a wonderful source of information.
Hello, i feel that i noticed you visited my weblog thus i got here
to return the desire?.I’m attempting to find issues to enhance my web site!I assume its good enough to
make use of a few of your concepts!!
My relatives every time say that I am wasting my time here at net, however I know
I am getting familiarity all the time by reading thes pleasant content.
I feel that is one of the most important info for me. And i’m happy studying
your article. But should observation on some general issues, The site taste is great,
the articles is truly nice : D. Just right activity,
cheers
Hi colleagues, its wonderful paragraph regarding teachingand entirely explained, keep it up all
the time.
An intriguing discussion is definitely worth comment.
I do think that you need to publish more
on this subject matter, it might not be a taboo subject but usually
people don’t speak about such subjects. To the next! Cheers!!
Hey there, You have done an incredible job. I’ll definitely digg it and personally recommend to my friends.
I’m confident they’ll be benefited from this site.
I know this site offers quality dependent content and
additional stuff, is there any other web site which presents these information in quality?
I used to be able to find good advice from your content.
Post writing is also a excitement, if you know then you can write or else it is complex to write.
Piece of writing writing is also a excitement, if you be
familiar with then you can write or else it is complex to write.
Hi, constantly i used to check webpage posts here in the early hours in the daylight,
for the reason that i enjoy to learn more and more.
What’s up, this weekend is fastidious in support of me, as this time i am reading this impressive
educational piece of writing here at my house.
When I initially left a comment I seem to have clicked the -Notify me when new
comments are added- checkbox and now every time a comment is added I get 4 emails with the same comment.
There has to be a means you can remove me from that service?
Cheers!
Valuable information. Fortunate me I discovered your site unintentionally, and I am surprised why
this twist of fate did not came about earlier! I bookmarked it.
If you want to get a great deal from this piece of writing then you have to apply these strategies to your won webpage.
My family members all the time say that I am
wasting my time here at web, however I know I am getting familiarity daily by reading thes fastidious posts.
It’s not my first time to go to see this web page, i am visiting this web page dailly and obtain pleasant
data from here every day.
you are actually a good webmaster. The site loading speed
is amazing. It sort of feels that you’re doing any distinctive
trick. Moreover, The contents are masterwork.
you have performed a great activity in this subject!