Skip to content

Commit 80aff38

Browse files
cleaned up prints
1 parent f321978 commit 80aff38

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

classroom/snippets/classroom_snippets.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ def create_course(self):
3838
'courseState': 'PROVISIONED'
3939
}
4040
course = service.courses().create(body=course).execute()
41-
print('Course created:', course.get('name'), course.get('id'))
41+
print('Course created: %s, %s' % (course.get('name'), course.get('id')))
4242
# [END classroom_create_course]
4343
return course
4444

@@ -48,9 +48,9 @@ def get_course(self, course_id):
4848
# [START classroom_get_course]
4949
try:
5050
course = service.courses().get(id=course_id).execute()
51-
print('Course "{%s}" found.', course.get('name'))
51+
print('Course "{%s}" found.' % course.get('name'))
5252
except errors.HttpError as error:
53-
print('Course with ID "{%s}" not found.', course_id)
53+
print('Course with ID "{%s}" not found.' % course_id)
5454
# [END classroom_get_course]
5555
return error
5656
return course

0 commit comments

Comments
 (0)