how to create obtain any random 3 items of list in python

Solutions on MaxInterview for how to create obtain any random 3 items of list in python by the best coders in the world

showing results for - "how to create obtain any random 3 items of list in python"
Beatrice
14 Jan 2019
1
2import random as R
3A=['a','b','c','d','e','f','g','h','i','j']
4print("\n",R.sample(A,3))