def makeImage(argdata, c):
 size = len(argdata)
 img = Image.new('RGB', (size, size), 'black')
 pixels = img.load()
 for i in range(img.size[0]):
  for j in range(img.size[1]):
   pixels[(j, i)] = ((255, 255, 255) if (argdata[i][j] == '+') else (0, 0, 0))
 img = img.resize(((size * 10), (size * 10)))
 img.save(('qrcode%d.png' % c))
 return img

def makeImage ( argdata , c ) : size = len ( argdata ) img = Image . new ( 'RGB' , ( size , size ) , 'black' ) pixels = img . load ( ) for i in range ( img . size [ 0 ] ) : for j in range ( img . size [ 1 ] ) : pixels [ ( j , i ) ] = ( ( 255 , 255 , 255 ) if ( argdata [ i ] [ j ] == '+' ) else ( 0 , 0 , 0 ) ) img = img . resize ( ( ( size * 10 ) , ( size * 10 ) ) ) img . save ( ( 'qrcode%d.png' % c ) ) return img
turn a code into an image .