{"id":7,"date":"2006-04-14T15:44:31","date_gmt":"2006-04-14T22:44:31","guid":{"rendered":"http:\/\/www.menasoft.com\/blog\/?p=7"},"modified":"2006-07-13T20:34:16","modified_gmt":"2006-07-14T02:34:16","slug":"how-well-do-you-know-c","status":"publish","type":"post","link":"https:\/\/www.menasoft.com\/blog\/?p=7","title":{"rendered":"How well do you know C++ ?"},"content":{"rendered":"<p>I found this a fun subject from a very old article. The August 97 issue of Dr. Dobbs Journal has an article that discusses tips for interviewing C++ programmer candidates. We all want to show off how smart we are don&#8217;t we? We have all heard some of these trick questions in interviews. Usually I think it has more to do with the interviewer trying to show off how smart they are. hehe. but they are still interesting.<br \/>\n<!--more--><\/p>\n<p>I wasn&#8217;t real solid myself on all the answers so I thought it was worth sharing. To see how well someone understands the fundamental differences between C and C++, try one of the following<\/p>\n<p>How do you link a C++ program to C functions?<br \/>\nExplain the scope resolution operator.<br \/>\nWhat are the differences between a C struct and a C++ struct? A C++ class?<br \/>\nHow many ways are there to initialize an int with a constant?<br \/>\nHow does throwing and catching exceptions differ from using setjmp and longjmp?<\/p>\n<p>If a candidate claims to have done class design for a project, here are some questions that reveal how well they understand the technology.<br \/>\nWhat is your reaction to the statement &#8220;delete this;&#8221;?<br \/>\nWhat is a default constructor?<br \/>\nWhat is a conversion constructor?<br \/>\nWhat is the difference between a C++ struct and a C++ class<br \/>\nWhen should you use multiple inheritance?<br \/>\nWhat is a virtual destructor?<br \/>\nExplain the ISA and HASA class relationships. How would you implement each in a class design?<br \/>\nWhen is a template a better solution than a base class?<\/p>\n<p>A bunch of other such questions can be found at an interesting site called <a href=\"http:\/\/www.techinterviews.com\/?p=226\">Tech Interviews<\/a><\/p>\n<p>It has more such questions in a number of different fields. Check out the &#8220;Windows Programming&#8221; test. It&#8217;s got some good stuff every windows programmer should probably know.<\/p>\n<p><a href=\"http:\/\/www.parashift.com\/c++-faq-lite\/\">http:\/\/www.parashift.com\/c++-faq-lite\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I found this a fun subject from a very old article. The August 97 issue of Dr. Dobbs Journal has an article that discusses tips for interviewing C++ programmer candidates. We all want to show off how smart we are don&#8217;t we? We have all heard some of these trick questions in interviews. Usually I [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[4],"tags":[],"class_list":["post-7","post","type-post","status-publish","format-standard","hentry","category-philosophic"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p5gVa-7","jetpack_sharing_enabled":true,"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/www.menasoft.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/7","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.menasoft.com\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.menasoft.com\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.menasoft.com\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.menasoft.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=7"}],"version-history":[{"count":0,"href":"https:\/\/www.menasoft.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/7\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.menasoft.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=7"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.menasoft.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=7"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.menasoft.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=7"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}