6. (3 points) Use 40 yuan to buy three types of exercise books priced at 2 yuan, 5 yuan, and 11 yuan each, with at least one of each type, and spend all the money. Then the number of different purchasing methods is $\qquad$ kinds.
【Analysis】Subtract 1 from each type, leaving $40-2-5-11=22$ yuan. Then, based on the remaining money, divide and solve the problem.

【Solution】Solution: Subtract 1 from each type, leaving $40-2-5-11=22$ yuan.
If you buy 2 more 11-yuan books, it will be exactly used up, counting 1 method;
If you buy 1 more 11-yuan book, 11 yuan remains, you can buy 1 5-yuan book and 3 2-yuan books, counting 1 method; if you do not buy 11-yuan books anymore, 22 yuan can buy at most 4 5-yuan books, the number of 5-yuan books can be $4,2,0$, counting 3 methods in total, $1+1+3=5$ methods.

Answer: There are 5 different ways to purchase.