본문 바로가기

IT/하루 코딩

유데미 Udemy - Python 부트캠프 : 100개의 프로젝트로 - 1일차

728x90
반응형

새해를 맞이해서 자기개발의 목적으로 유데미 100일 프로젝트 강의를 시작했습니다.

코딩에 대해서는 전혀 알지못하는 평범한 직장인입니다

 

100개 과제가 끝이느난 순간 원하는 자료를 추출할 수 있는 능력이 생기길 기대하며 시작하겠습니다. 

 

 

https://replit.com

 

 

Replit: the collaborative browser based IDE

Run code live in your browser. Write and run code in 50+ languages online with Replit, a powerful IDE, compiler, & interpreter.

replit.com

1일차 강의는 해당 사이트에서 연습 진행 

 

출력함수 

print( "Hello World!")

print("Hello" +" " + "python")   : Hello python

* IndentationError: unexpected indent  : 띄어쓰기 오류에 대한 정보 

 

 

* test 

print("Day 1 - Python Print Function")
print("The function is declared like this:")
print("print('what to print')")


Day 1 - Python Print Function
The function is declared like this:
print('what to print')
 

print(Day 1 - String Manipulation")
print("String Concatenation is done with the "+" sign.")
  print('e.g. print("Hello " + "world")')
print(("New lines can be created with a backslash and n.")
 #Fix the code below 👇

print("Day 1 - String Manipulation")
print('String Concatenation is done with the "+" sign.')
print('e.g. print("Hello " + "world")')
print("New lines can be created with a backslash and n.")

- 2번쨰 "+"가  앞뒤 코딩에 " "로 작성되면 띄어쓰기로 인식되는 디버깅 발생 →  ' ' 로 수정 후 작성 필요

 

print("what is your name?")  끝남 

 : 
input("what is your name?") :  답변을 이어서 받음 

 

변수 
#Write your code below this line 👇
print(len(input("what is your name?")))
# 🚨 Don't change the code below 👇
a = input("a: ")
b = input("b: ")
# 🚨 Don't change the code above 👆

####################################
#Write your code below this line 👇

c=a
a=b
b=c

#Write your code above this line 👆
####################################

# 🚨 Don't change the code below 👇
print("a: " + a)
print("b: " + b)
 
정말 간단한건데 생각보다 답을 보기전엔 몰랐다 
1강 종합 
#1. Create a greeting for your program.
print("밴드이름 생성기에 오신걸 환영합니다.")

#2. Ask the user for the city that they grew up in.
city = input("자란 도시가 어디인가요")

#3. Ask the user for the name of a pet.
pet = input("당신의 애완동물 이름은 무엇인가요?")

#4. Combine the name of their city and pet and show them their band name.
print("당신의 밴드이름은"+ city + pet)
#5. Make sure the input cursor shows on a new line:

 

 

728x90
반응형