daily pastebin goal
15%
SHARE
TWEET

Untitled

a guest Dec 18th, 2018 58 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. S = input()
  3. A = S.split(' ')
  4. newS = []
  5. for i in range(len(A)):
  6.     if i % 3 != 0:
  7.         newS.append(A[i])
  8. print (newS)
  9.  
  10.  
  11.  
  12. H = input()
  13. A = H.split(' ')
  14. newH = []
  15. for i in range(len(A)):
  16.     if i % 3 != 0:
  17.         newH.append(A[i])
  18. print (newH)
  19.  
  20.  
  21.  
  22. xfinal = []
  23. yfinal = []
  24. for e in newS:
  25.     if e in newH and e.isdigit() == False:
  26.          xfinal.append(newS[newS.index(e)+1])
  27.          yfinal.append(newH[newH.index(e)+1])
  28. print (xfinal)
  29. print (yfinal)
  30.  
  31. import matplotlib.pyplot as plt
  32. fig, ax = plt.subplots()
  33. ax.bar(xfinal, yfinal, label="")
  34. ax.legend()
  35. plt.show()
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top