<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: notyourcuppachai</title>
    <description>The latest articles on Forem by notyourcuppachai (@notyourcuppachai).</description>
    <link>https://forem.com/notyourcuppachai</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F921230%2Fb2a12bc4-6d7a-42b3-bf65-b480f6ad75aa.png</url>
      <title>Forem: notyourcuppachai</title>
      <link>https://forem.com/notyourcuppachai</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/notyourcuppachai"/>
    <language>en</language>
    <item>
      <title>Day 1: Getting the basics down</title>
      <dc:creator>notyourcuppachai</dc:creator>
      <pubDate>Wed, 07 Sep 2022 18:02:10 +0000</pubDate>
      <link>https://forem.com/notyourcuppachai/day-1-getting-the-basics-down-1o70</link>
      <guid>https://forem.com/notyourcuppachai/day-1-getting-the-basics-down-1o70</guid>
      <description>&lt;p&gt;Things I learnt on &lt;strong&gt;Day 1&lt;/strong&gt; of coding Python:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Using the "F string" to join text with variables used in the code &lt;/li&gt;
&lt;li&gt;How to create functions and how to call functions&lt;/li&gt;
&lt;li&gt;Setting up if and elif statements within the code&lt;/li&gt;
&lt;li&gt;How to use a dictionary and call elements within the dictionary&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Listening to the course I felt like it was easy and I got the basics down, however, when I tried to recreate the game (Of course it was the Rocks, Paper, Scissors game) I was lost in the nitty gritty of it all and struggled in almost every line of how to do certain things.&lt;/p&gt;

&lt;p&gt;On my 2nd try yesterday, I did manage to get it right, being a bit slower and taking only a litttlee bit of help from the tutorial.&lt;/p&gt;

&lt;p&gt;However, today, when I revisited the game, I was able to recreate almost 91% of the code by myself and only needed a bit of clarification at the end. &lt;/p&gt;

&lt;p&gt;So, here is my 91% of the code I recreated again. I know it is basic, but it helps me keep track and learn.&lt;/p&gt;

&lt;h2&gt;
  
  
  CODE: ROCK, PAPER, SCISSORS
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import random

def get_choices():
    player_choice = input("Enter your choice :")
    options = ["rock", "paper", "scissors"]
    computer_choice = random.choice(options)
    choices = {"player": player_choice, "computer": computer_choice}
    return choices


def check_winner(playerchoice, computerchoice):
    print(f"You chose {playerchoice} and computer chose {computerchoice}")

    if playerchoice == computerchoice:
        return "It is TIE"
    elif playerchoice == "rock":
        if computerchoice == "paper":
            return "Paper covers rock. You lose!"
        elif computerchoice == "scissors":
            return "Rock smashes scissors. You win!"
    elif playerchoice == "paper":
        if computerchoice == "rock":
            return "Paper covers rock. You win!"
        elif computerchoice == "scissors":
            return "Paper cut by scissors. You lose!"
    elif playerchoice == "scissors":
        if computerchoice == "paper":
            return "Paper cut by scissors. You win!"
        elif computerchoice == "rock":
            return "Rock smashes scissors. You lose!"


choices = get_choices()
result = check_winner(choices["player"], choices["computer"])
print(result)

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>python</category>
      <category>beginners</category>
      <category>programming</category>
    </item>
    <item>
      <title>Day 0: Deep Breath and START!</title>
      <dc:creator>notyourcuppachai</dc:creator>
      <pubDate>Mon, 05 Sep 2022 15:10:29 +0000</pubDate>
      <link>https://forem.com/notyourcuppachai/day-0-deep-breath-and-start-3469</link>
      <guid>https://forem.com/notyourcuppachai/day-0-deep-breath-and-start-3469</guid>
      <description>&lt;p&gt;Hello All,&lt;/p&gt;

&lt;p&gt;I am Chai, here to learn programming and am excited to create apps and automations as I learn new things. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;My Why?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Why do I want to learn programming? For many reasons, and maybe they are connected, maybe not. I will discover as I go through these goals and learn and develop.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;Independence: I want to learn so that I can have a bigger freedom in choosing my work times, my career and where I want to work, my holidays, etc. And let's not gloss over the fact that tech is big money and this is one perk I definitely look forward to (once I am a seasoned coder, that is). So financially, career-wise, etc I want to be independent.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;I am lazy: I feel like I have soo soo many ideas on how to make tasks easier or automated, if &lt;strong&gt;&lt;u&gt;ONLY&lt;/u&gt;&lt;/strong&gt; I knew how to code. And so, here I have come, to not have to use this excuse anymore. I want to empower myself to do what I want, without feeling helpless or useless.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Challenging: I am ready to challenge myself and see where I can go. I have always loved learning and I think I can use this opportunity not only to learn, but how to learn and rewire the way my brain thinks.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;And with that, here i am today. It is Day 0. &lt;/p&gt;

&lt;p&gt;So what is my &lt;strong&gt;aim&lt;/strong&gt; for today? To get myself set up, signed up and create accounts in Github, StackOverflow, etc. I have done all of this, and somehow I feel so so overwhelmed.  (if you are self-taught, how did you manage all this and not run away?)&lt;/p&gt;

&lt;p&gt;And maybe, I might also start with a few videos already so that I can get a head start into this.&lt;/p&gt;

&lt;p&gt;If you are like me, and starting on this journey, then come say hi. I would love to follow you on your journey as well. &lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
