Python programming problem

I'm teaching myself programming and Python. So, this is probably a ridiculously obvious question to many. I'm trying to take an input that includes 1) student name and 2) an indeterminate amount of grades. I want to assign the grades to a student and allow for as many student and grade combos as possible.

My problem is I can't figure out how I continuously receive user input without overwriting previous user input. I've tried a for loop, a while loop, using a list of lists with lists [ [student, [grades] ], [student, [grades] ] ] and a dictionary with a list { student : [grades], student : [grades] } 

def main ( ) :

name_prompt = input ( '\n Enter the student's name: ' )

grade_num = int ( input ( '\n Enter the number of grades you want to enter: ' ) )

grade_array = list ( )

## access_dict = dict ( )

 

count = 0

while count < grade_num:

grade_prompt = float ( input ( '\nEnter grade: ' ) )

grade_array.append ( grade_prompt )

access_array = [ name_prompt, grade_array ]

## access_dict [ name_prompt ] = grade_array

## access_array = [ access_dict ]

## thought I might be able to use append or __setitem__ after the first loop to add item to end of list/dict and                  thus not overwrite

if count >= 1:

access_array.append ( name_prompt, grade_array )

#access_dict.__setitem__( name_prompt, grade_array )

count += 1

rerun = input('\n Do you want to enter another student? ')

if rerun in ('y','Y','yes','Yes','ok','OK','okay','yup','yah','yep','yeah','indubitably bro'):

main ( )

 

Also, is there a Stack Exchange for beginners? 

Try this :

#!/usr/bin/env python

import re

stored_students_and_grades = {}

def parse_input(input_string):

    # Split the input string into student object and grades

    list_of_inputs = re.split(' ', input_string)

    student = list_of_inputs[0]

    grades = list_of_inputs[1:]

    return [student , grades]

 

while 1:

    input_string = input("Enter student name folowed by grades (or exit if you want to exist):")

    student, grades = parse_input(input_string)

    if student == "exit":

        break

    else:

        stored_students_and_grades[student] = grades

print(stored_students_and_grades)

 

If you have any questions ask me.

I'm learning as well. Can you please show me the output you'd like to see, as if running the program?