I believe you are looking for template suggestions, see Drupal 6 Template Suggestions, one of the Drupal provided theme suggestions will do it for you.
I think the one you are looking for is page-node-[node-id].tpl.php
Alternatively you can create your own theme suggestions, see Working with template suggestions
Edit: It depends on what you want the code to accomplish if this answer is correct or not, if it's something related to display then templates may be correct, but if itit's data manipulation then you may be better off with template_preprocess_node
Alternatively if you want to execute arbitrary code not directly related to just the theming of the node, I think you would use hook_nodeapi or hook_view