Programming something is a lot more than just typing some things into a file and hoping for the best.
How many lines of code something is does not matter.
What matters is that it makes sense. The simply not negotiable.
What you wrote above does not make sense in an isolated context.
ALSO, don’t reply to 2.5-year-old necro forum posts.
Instead, follow some Unity tutorials that seem to feature jumping, and when you have an issue, start your own brand new thread, and read this before you post:
How to report problems productively in the Unity3D forums:
Help us to help you.
If you post code, read here for how to do so properly: Please use code tags: https://discussions.unity.com/t/481379