Skip to content

Mathematical, Random, and Platform Utilities

Step 5 of 41

Sampling and Platform Inspection

Introduction

This lesson covers objectives 1.3 and 1.4 of PCAP-31-03, both part of the Modules and Packages section (12% of the score, 6 of the 40 items). Objective 1.3 asks you to use the random module: random(), seed(), choice() and sample(), together with the related integer functions you will meet in practice. Objective 1.4 asks you to use the platform module to find out which machine and which Python are running your code: platform(), machine(), processor(), system(), version(), python_implementation() and python_version_tuple().