Since the ratio of apples to oranges is 3:1, that means for every 3 apples there is 1 orange. The size of this group is therefore 3+1=<<3+1=4>>4.
We then divide this group size into the total amount of fruit the basket is holding at this time, which is 40. This means there are 40/4=<<40/4=10>>10 of these groups in total.
Since there are 10 of these groups in total, that means there are 10*1=<<10*1=10>>10 oranges in the basket.
#### 10