You could try $thread[forumid] rather than $GLOBALS[forumid] so:
Code:
<if condition="(($post[postcount]==1) or ($post[islastshown] AND !in_array($thread[forumid], array(46,51,58,69,75,95,97,100,103))))">
google ads
</if>
Also when do you want to show the ad, as your condition is written it will:
ALWAYS show in the first ad in the first post in every forum
and show in the Last Post if not in the forums you specify.
That's how its written, is that what you want to do?