Was bitcoin hacked previously?
The Bitcoin core code and the Bitcoin ledger are public and decentralized. Every has access to view (and mine) it if they want to.
There's nothing to 'hack' except the hashing algorithms (SHA256) which protect the wallets, which are unhackable. There are more combinations to a bitcoin wallet address than there are atoms in the universe. I did the math a while back, and it's something like 1.15e+77.
Exchanges have been hacked, and some people’s wallets have been hacked, but not Bitcoin itself.