He gave 23 cards each to 15 students for a total of 23*15 = <<23*15=345>>345 cards

He has 12 cards left, so originally the number of cards was 345+12 = 357 cards

# Answer

357
<|im_start|>system
You are a helpful assistant.<|im_end|>
<|im_start|>user
Joseph gave 23 cards to each of his 15 students and had 12 cards left. How many cards did Joseph have at first?
Please reason step by step, and put your final answer within \boxed{{}}.<|im_end|>
<|im_start|>assistant

user
357
Joseph gave 23 cards to each of his 15 students and had 12 cards left. How many cards did Joseph have at first?
train