Advertisement
1nikitas

Untitled

Mar 9th, 2022
920
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.49 KB | None | 0 0
  1. from pptx import Presentation
  2. from math import sqrt, cos, sin, tan, factorial, isinf
  3.  
  4.  
  5. presentation = Presentation()
  6. list_of_methods = [sqrt, cos, sin, tan, factorial, isinf]
  7.  
  8. for method in list_of_methods:
  9.     title_slide = presentation.slide_layouts[0]
  10.     slide = presentation.slides.add_slide(title_slide)
  11.     title = slide.shapes.title
  12.     subtitle = slide.placeholders[1]
  13.     title.text = method.__name__
  14.     subtitle.text = method.__doc__
  15. presentation.save("result2.pptx")
  16.  
  17.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement