The first thing you said was "2-methyl propyl octane". The closest compound that this resembles in name is 4-(2-methylpropyl)octane, which is not the same:
The "2" indicates that the methyl is two carbons away from the backbone, and the "propyl" indicates that the propyl group is connected to the backbone at position "4". You also need hyphens in between a number and a subsequent group, and a hyphen between a number and an open parenthesis.
If I took "4-(1,1-dimethyl ethyl octane)" literally, it wouldn't be a real compound. Octane by itself is a real straight-chained alkane, and without that name outside the parentheses, you have no central structure for the alkane. Hence, it would be an incomplete name.
What you wrote has some off parentheses, and has some extra spacing, but it's closer than the first. It resembles 4-(1,1-dimethylethyl)octane, which would be correct.
The "4-(1,1-dimethyl ethyl)" indicates that an ethyl group is attached to position "4", and on the first carbon away from the backbone, there are two methyl groups.