<?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: Hachikoi</title>
    <description>The latest articles on Forem by Hachikoi (@8koi).</description>
    <link>https://forem.com/8koi</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%2F609644%2F94a20aaa-8189-43fd-80e2-f3e310a4a578.jpg</url>
      <title>Forem: Hachikoi</title>
      <link>https://forem.com/8koi</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/8koi"/>
    <language>en</language>
    <item>
      <title>First ever hackaton</title>
      <dc:creator>Hachikoi</dc:creator>
      <pubDate>Tue, 18 Apr 2023 05:03:31 +0000</pubDate>
      <link>https://forem.com/8koi/first-ever-hackaton-e2d</link>
      <guid>https://forem.com/8koi/first-ever-hackaton-e2d</guid>
      <description>&lt;p&gt;I always wanted to be part of a hackaton, and recently gave myself the opportunity, was so much fun, but since it took me so much I was pretty much the one teaching and guiding my team (2 more devs that touched react for their first time)&lt;/p&gt;

&lt;p&gt;Once again I can confirm that I really like teaching, so kind of aiming for a devrel role as of late, anyhow!&lt;/p&gt;

&lt;p&gt;It's a little app that fetches motivational quotes from chatgpt API &amp;amp; images from unsplash, once the quote is loaded you can change the image by selecting the ones in the bottom.&lt;/p&gt;

&lt;p&gt;Already got a bunch of... pretty direct feedback from the hackaton host, so what you see now will change a lot~&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--YAX7xLy9--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_800/https://www.inspirebot3000.com/external/IB3K.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--YAX7xLy9--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_800/https://www.inspirebot3000.com/external/IB3K.gif" alt="quotes" width="420" height="420"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--8_pXP-pd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_800/https://www.inspirebot3000.com/external/IB3KCarousel.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--8_pXP-pd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_800/https://www.inspirebot3000.com/external/IB3KCarousel.gif" alt="image selector" width="420" height="420"&gt;&lt;/a&gt;&lt;br&gt;
Deploy link: &lt;a href="https://www.inspirebot3000.com/"&gt;https://www.inspirebot3000.com/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Github: &lt;a href="https://github.com/chat-gpt-hack/Inspire-GPT"&gt;https://github.com/chat-gpt-hack/Inspire-GPT&lt;/a&gt;&lt;/p&gt;

</description>
      <category>react</category>
      <category>hackaton</category>
      <category>chatgpt</category>
      <category>beginners</category>
    </item>
    <item>
      <title>React + Moralis templates</title>
      <dc:creator>Hachikoi</dc:creator>
      <pubDate>Tue, 09 Aug 2022 21:48:07 +0000</pubDate>
      <link>https://forem.com/8koi/react-moralis-templates-2nbb</link>
      <guid>https://forem.com/8koi/react-moralis-templates-2nbb</guid>
      <description>&lt;p&gt;After a couple of weeks of trying to find a solution to prompt the user to change networks if they are in the wrong one, I finally found the solution while scrolling trough the docs and made a light-weight template for any case escenario&lt;/p&gt;

&lt;p&gt;They are all in an account I specially use to store templates, so feel free to follow my main account or contribute whit things you thing are missing!&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;React + Moralis&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/Hachikoi-Marine/React-Moralis-Template.git"&gt;https://github.com/Hachikoi-Marine/React-Moralis-Template.git&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;React + Router-dom + Moralis&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/Hachikoi-Marine/React-router-Moralis-template.git"&gt;https://github.com/Hachikoi-Marine/React-router-Moralis-template.git&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Next + Moralis&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/Hachikoi-Marine/Nextjs-Moralis-Template.git"&gt;https://github.com/Hachikoi-Marine/Nextjs-Moralis-Template.git&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>web3</category>
      <category>react</category>
      <category>nextjs</category>
      <category>moralis</category>
    </item>
    <item>
      <title>My very first portfolio</title>
      <dc:creator>Hachikoi</dc:creator>
      <pubDate>Tue, 18 Jan 2022 22:44:01 +0000</pubDate>
      <link>https://forem.com/8koi/my-very-first-portfolio-2pge</link>
      <guid>https://forem.com/8koi/my-very-first-portfolio-2pge</guid>
      <description>&lt;p&gt;&lt;a href="https://hachikoi-the-creator.github.io/index.html"&gt;Visit&lt;/a&gt;&lt;br&gt;
&lt;a href="https://github.com/Hachikoi-the-creator/Hachikoi-the-creator.github.io"&gt;Github Code&lt;/a&gt;&lt;br&gt;
This is my baby, I hate it/love it so much, please leave any kind of feedback I want to become a better dev!&lt;/p&gt;

</description>
      <category>sass</category>
      <category>javascript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Just finished my 3rd webpage!</title>
      <dc:creator>Hachikoi</dc:creator>
      <pubDate>Mon, 06 Dec 2021 22:39:54 +0000</pubDate>
      <link>https://forem.com/8koi/just-finished-my-3rd-webpage-4pa9</link>
      <guid>https://forem.com/8koi/just-finished-my-3rd-webpage-4pa9</guid>
      <description>&lt;p&gt;Just finished a course in Scrimba about HTML &amp;amp; CSS, cool platform&lt;br&gt;
Really liked the end product, appreciate any feedback!!&lt;br&gt;
Was able to upload it just now!&lt;br&gt;
&lt;a href="http://randomy.freecluster.eu/?i=1"&gt;My page C:&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Sauce:&lt;br&gt;
&lt;a href="https://github.com/Hachikoi-the-creator/3rd_Webpage.git"&gt;Look it up :P&lt;/a&gt;&lt;/p&gt;

</description>
      <category>html</category>
      <category>css</category>
    </item>
    <item>
      <title>My first python project!</title>
      <dc:creator>Hachikoi</dc:creator>
      <pubDate>Thu, 22 Apr 2021 02:56:01 +0000</pubDate>
      <link>https://forem.com/8koi/my-first-python-project-1ki9</link>
      <guid>https://forem.com/8koi/my-first-python-project-1ki9</guid>
      <description>&lt;h1&gt;
  
  
  Tick Tack Toe
&lt;/h1&gt;

&lt;p&gt;From a course I bought in Udemy&lt;br&gt;
I think I covered any possible type error that the user could make, please tell me if I´m missing something!!&lt;/p&gt;

&lt;p&gt;What it does?&lt;br&gt;
-Ask the user to choose between X or O as a marker &lt;br&gt;
-Random to choose who is first&lt;br&gt;
-Verifies it´s an empty space&lt;br&gt;
-Then places the marker in a place that the player chooses&lt;br&gt;
-Verifies is someone has won&lt;br&gt;
-So on, so on&lt;br&gt;
-At the end ask if they want to play again&lt;/p&gt;

&lt;p&gt;I first try it without any help for 4 days,&lt;br&gt;
then finished whit some kind of walkthrough they give and then I mixed what I like and what they used to optimize my project! Whit a total of 7 days and approx. 800 written lines of code!!&lt;/p&gt;

&lt;h3&gt;
  
  
  Pro tip:
&lt;/h3&gt;

&lt;p&gt;To upload code just go to the programs you use, select all the code + tab + control c&lt;br&gt;
Then just paste it here!&lt;/p&gt;

&lt;h2&gt;
  
  
  code
&lt;/h2&gt;

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

def final_display(display1,numepad):  #Yei! すき！好き！スキ！1-9r
    print(''*3)
    print(display1[:3],'°-°',numepad[:3])
    print('---------------',' + ','---------')
    print(display1[3:6],'°_°',numepad[3:6])
    print('---------------',' + ','---------')
    print(display1[6:],'°_°',numepad[6:])
    print('---------------',' + ','---------')

def choice_xy():
    print("Welcome to my tic tac toe game!~")
    choice = input("Do you want X or O?: ")
    while choice.lower() not in ['x','o']:
        choice = input("I said X or O?... ")
    if choice.lower() == 'x':
        return 'X','O'

    else:
        return 'O','X'

def place_symbol(display2,symbol,where):  #just places the correct symbol
    display2[where] = symbol

def win_check(board,mark):
    #Checks for all the Rows
    #then all the Columns
    #at least if the diagonals are equial to each other and the Marker
    if board[0] == mark and board[1] == mark and board[2] == mark:
        return True
    elif board[3] == mark and board[4] == mark and board[5] == mark:
        return True
    elif board[6] == mark and board[7] == mark and board[8] == mark:
        return True
    elif board[0] == mark and board[3] == mark and board[6] == mark:
        return True
    elif board[1] == mark and board[4] == mark and board[7] == mark:
        return True
    elif board[2] == mark and board[5] == mark and board[8] == mark:
        return True
    elif board[6] == mark and board[4] == mark and board[2] == mark:
        return True
    elif board[0] == mark and board[4] == mark and board[8] == mark:
        return True
    else:
        return False

def random_turn():
    turn = random.randint(1,2)
    if turn == 1:
        #print('Player 1')
        return turn
    else:
        #print('Player 2')
        return turn

def available_check(display3,position3):
    #Returns bool to check is the space is available
    return not display3[position3-1].isupper()
    #True == Occupied, False == Empty

def full_display(display7):
    #Checks if the display is full == True
    counter = 0
    for i in [1,2,3,4,5,6,7,8,9]:
        if display7[i-1] in 'X' or display7[i-1] in 'O':
            counter += 1
    return counter == 9

def where_put_it():  #Ask where to put the marker and verifies is in 1-9
    where = input('Where do you want to make your move?(1-9) ')
    while where not in ('1','2','3','4','5','6','7','8','9'):
        where = input('違う Invalid move, try again .... ')
    where2 = int(where)
    return where2

def play_again_ask():   #If wanna play again, returns True
    choice = input('Wanna play again?(Yes or No): ')
    while choice.lower() not in ['yes', 'no']:
        choice = input('あのさ。。Yes or No: ')
    if choice.lower() == 'yes':
        return 'yes'
    else:   #Just can be 'yes' or 'no'
        return 'no'

def pc_gaming():
    display0_0 = [' ',' ',' ',
                  ' ',' ',' ',
                  ' ',' ',' ']
    numepad = [1, 2, 3,
               4, 5, 6,
               7, 8, 9]
    player1S,player2S = choice_xy()
    if random_turn() == 1:
        turnCast = 1
        print('Player 1 goose first~')
    else:
        turnCast = 2
        print('Player 2 goose first~')

    while not full_display(display0_0):
        if turnCast % 2 == 0:
            print('Player 2´s turn~')
            final_display(display0_0, numepad)
            castPosition = where_put_it()-1  # Checks is in 1-9
            ##################
            while display0_0[castPosition].isupper():
                print('-Occupied field-')
                castPosition = where_put_it()-1
            place_symbol(display0_0,player2S,castPosition)
            if win_check(display0_0,player2S):
                final_display(display0_0, numepad)
                print('Player 2 WINS!')
                break

        elif turnCast % 2 != 0:
            print('Player 1´s turn~')
            final_display(display0_0,numepad)
            castPosition = where_put_it()-1  # Checks is in 1-9
            ##############
            while display0_0[castPosition].isupper():
                print('-Occupied field-')
                castPosition = where_put_it()-1
            place_symbol(display0_0,player1S,castPosition)
            if win_check(display0_0,player1S):
                final_display(display0_0, numepad)
                print('Player 1 WINS!')
                break

        turnCast += 1
    if not(win_check(display0_0,player1S) and win_check(display0_0,player1S)) and full_display(display0_0):
        print('Nobody wins...')

pc_gaming()
response = play_again_ask()
if response.lower == 'yes':
    pc_gaming()
else:
    print('Thanks for playing!')
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
      <category>python</category>
      <category>beginners</category>
    </item>
    <item>
      <title>Short Python Problem</title>
      <dc:creator>Hachikoi</dc:creator>
      <pubDate>Wed, 07 Apr 2021 20:22:04 +0000</pubDate>
      <link>https://forem.com/8koi/short-python-problem-3de4</link>
      <guid>https://forem.com/8koi/short-python-problem-3de4</guid>
      <description>&lt;p&gt;I was also struggling whit this one... didn´t really search for any help tho.&lt;br&gt;
Source: &lt;a href="https://codingbat.com/prob/p129125"&gt;https://codingbat.com/prob/p129125&lt;/a&gt;&lt;br&gt;
 &lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--m4wDNLVx--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2h4o1vprf9op7guvt54f.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--m4wDNLVx--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2h4o1vprf9op7guvt54f.jpg" alt="Alt Text" width="658" height="366"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>python</category>
      <category>beginners</category>
    </item>
    <item>
      <title>"Easy" exercise solved</title>
      <dc:creator>Hachikoi</dc:creator>
      <pubDate>Tue, 06 Apr 2021 19:51:36 +0000</pubDate>
      <link>https://forem.com/8koi/easy-exercise-solved-4h5f</link>
      <guid>https://forem.com/8koi/easy-exercise-solved-4h5f</guid>
      <description>&lt;p&gt;I was struggling so bad whit this exercise found in codingBat (&lt;a href="https://codingbat.com/prob/p113659"&gt;https://codingbat.com/prob/p113659&lt;/a&gt;) asking for a output of the first 3 numbers of pi&lt;br&gt;
Result: &lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--KzQD5Y8x--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ioez0gw76vqp2cnpnkge.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--KzQD5Y8x--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ioez0gw76vqp2cnpnkge.jpg" alt="Alt Text" width="273" height="220"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>python</category>
      <category>beginners</category>
    </item>
  </channel>
</rss>
