3 deleted 44 characters in body
source | link

Python 3, 12293

v={'p':1v=dict(zip('pbnrqPBNRQ','b':[1,3,'n':3,'r':5,'q':9,'k':0}9]*2))
s=[0print(sum(v.get(c,0]
0)*(-1)**(c>'Z')for c in input():
 if c.isalpha():s[c in v]+=v[c.lower()]
print(s[0]-s[1])

Python 3, 122

v={'p':1,'b':3,'n':3,'r':5,'q':9,'k':0}
s=[0,0]
for c in input():
 if c.isalpha():s[c in v]+=v[c.lower()]
print(s[0]-s[1])

Python 3, 93

v=dict(zip('pbnrqPBNRQ',[1,3,3,5,9]*2))
print(sum(v.get(c,0)*(-1)**(c>'Z')for c in input()))
2 deleted 22 characters in body
source | link

Python 3, 134122

v={'p':1,'b':3,'n':3,'r':5,'q':9,'k':0}
w=b=0s=[0,0]
for c in input():
 if c.isalpha():
  if cs[c in v:b+=v[c]
  else:w+=v[cv]+=v[c.lower()]
print(ws[0]-bs[1])

Python 3, 134

v={'p':1,'b':3,'n':3,'r':5,'q':9,'k':0}
w=b=0
for c in input():
 if c.isalpha():
  if c in v:b+=v[c]
  else:w+=v[c.lower()]
print(w-b)

Python 3, 122

v={'p':1,'b':3,'n':3,'r':5,'q':9,'k':0}
s=[0,0]
for c in input():
 if c.isalpha():s[c in v]+=v[c.lower()]
print(s[0]-s[1])
1
source | link

Python 3, 134

v={'p':1,'b':3,'n':3,'r':5,'q':9,'k':0}
w=b=0
for c in input():
 if c.isalpha():
  if c in v:b+=v[c]
  else:w+=v[c.lower()]
print(w-b)