If there are 2/5 times as many books as the number of tables in the class on top of each table, there are 2/5*500 = <<2/5*500=200>>200 books.
Since the class has 500 tables with 200 books on top of each, there are 500*200 = <<500*200=100000>>100000 books.
#### 100000