Using instances of classes as variables in a function?
The following is a code that provides me with a syntax errors when I run it: class HearthStone(): '''Models a hearthstone card''' def __init__(s, name, mana, attack, health): s.name = name s.mana = mana s.attack = attack s.health = health def show_info(s): ''' Displays basic card info ''' print( 'Name: ' + str(s.name.title())+ '\nMana cost: ' + str(s.mana) + '\nHealth: ' + str(s.health) + '\nAttack: ' + str(s.attack) ) def attack(s, target): '''Lets try this again''' print(s.name.title() + ' [' + str(s.health) + '/' + str(s.attack) + '] ' + ' V.S. ') print(s.target.name.title() + ' ['+str(target.s.health) + '/'+str(target.s.attack) + ']') chillwind_yeti = HearthStone('chillwind yeti', 4, 4, 5) chillwind_yeti.show_info() carrion_grub = HearthStone('carrion grub', 3, 2, 5) chillwind_yeti.attack(carrion_grub) It says the syntax error is on the line where I define the variable 'carion_grub' and I was curious as to what I was doing wrong, and how to use other instances of a class in the function of another instance in general. Thanks!