24.03.10 python 기본 연습
class Puppy: def __init__(self, name, breed): self.name = name self.age = 0.1 self.breed = breed def __str__(self): return f"Puppy named {self.name}, breed:{self.breed}" ruffus = Puppy( name ="Ruffs", breed ="Beagle", ) bibi = Puppy( name="BiBi", breed="Dalmatian", ) print( bibi.name, bibi.breed, ruffus.name, ruffus.breed, ) print(bibi, ruffus, ) class Puppy: def __init__(self, name, breed): sel..
24.02.23 html css js 연습 1일차
//추가하기, push() 뒤에서, unshift 앞에 console.log('before :'+myArray); myArray.unshift('orange'); console.log('after :'+myArray); ---------------------------------- before :1,3.14,true,banana,3.14,true after :orange,1,3.14,true,banana,3.14,true //array in array const myArray = [1, [3.14, true, 'banana', 3.14], true]; // console.log(myArray); console.log('before :'+myArray); const value = myArray.shift(..