Python programming

homework

#1

Write a script to produce the following table of sin and cos values for angles ranging from 0 to 2π radians, in increments of π / 6. Use a for-loop and a range to generate the angles. Since a range only generates integer values, you will have to multiply the integer by the angle increment.

Use format strings and the format function to produce each line of output. DO NOT hard-code blanks into your format strings (or Adam will personally admonish you). Use format place holders that centre the values. You may include the vertical bar directly into the format strings.


#2

Hopefully Adam does not find this post or you will get zero for letting other people do your work for you.