9=total number of cups of flour needed

3=number of cups she has put in

x=number of cups she needs to add

3+x=9

3+x-3=9-3

x=6