Home > other >  How do you write this in python
How do you write this in python

Time:10-14

Using the Python language. Write a function called the create_user, this function has three parameters, a parameter called the name used to pass the user name, called a role is used to pass, the default value is 3, the last one for the variable parameter info dictionary used to store other information, this function is used to create the user and the output created by the user's user name, character and other information, if the user is null output with account can't be empty, user_role role information stored in the dictionary, the dictionary information for {0: "root", rank 1: "admin", 2: 'user', 3: 'guest'}, call this function to create a user, the user's information as follows: the user name xusanduo, roles for the user and other information to depart: IT, birthday: 2000-10-1, final output format for: create a xusanduo and roles for the user, other information for {' depart: 'IT', 'birthday', '2000-10-1'} the users!
  • Related