Role Wise Authorization

Hi,

i want to assign role for user(student,admin).and as per user role perform action(insert,update,delete,view Records).but without using any extensions or widgets.

i want simple code.that when student logins, then that student can only view data.

and suppose admin logins,then admin can add,update,delete records.

Thanks