Skip to content

Commit Live PR #288

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Done
  • Loading branch information
paragDC committed Sep 7, 2018
commit 85c780f810c5b10b64f722ce9f3e70396d0a4099
15 changes: 11 additions & 4 deletions q04_count/build.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,18 @@
# %load q04_count/build.py
# Default Imports
from greyatomlib.python_getting_started.q01_read_data.build import read_data
data = read_data()


# Your Solution Here
def deliveries_count(data=data):

# Your code here


count = 0
first_innings = data['innings'][0].get('1st innings').get('deliveries')
count = 0
for x in range(0,len(first_innings)):
delivery = first_innings[x]
for key in delivery:
if delivery[key].get('batsman') == 'RT Ponting':
count = count+1
return count