If I jailbreak my iphone 4 would i be able to update to ios 8?

If I jailbreak my iphone 4 would i be able to update to ios 8?

No. The latest it will ever run is 7.1.2 no matter what you do. Apple did not release iOS 8 for the iPhone 4.

Currently there's no Jailbreak for IOS 8, if you Jailbreak IOS 7 you can update to IOS 8 however it will remove the Jailbreak, you can either update now or wait until there's an IOS 8 Jailbreak which could be months maybe even a year away.