Answer:
$3 times 3 times 4 = 6 times 6 times 24 = 864 ways
Step-by-step explanation:
First, let's consider the books that must be together. Since there are 4 different history books and at least 3 of them must be together, we can treat these 3 history books as a single "block" that can be arranged in $3 ways. Within this block of history books, the order of the books can be rearranged in $3 ways.
Now, we have 3 different math books and 1 block of 3 history books on the bookshelf, which can be arranged in $4 ways.
Therefore, the total number of ways to arrange the books on the bookshelf is $3 times 3 times 4 = 6 times 6 times 24 = 864 ways