'\n' - newline
'\b' - back space
'\v' - vertical tab
'\f' - form feed
'\?' - Double quote
Comment line :-
प्रोग्राम में क्रियाओं, परिणामों एवं अन्य गतिविधियों से सम्बन्धित जानकारी प्रोग्रामर स्वयं की जानकारी के लिए उपयुक्त स्थान पर कुछ पंक्तियों के रूप में लिखता है, जिन्हें सी कम्पाइलर क्रियान्वित नहीं करती है. इन्हें टिप्पणी कहते हैं। टिप्पणी का प्रयोग प्रोग्राम में निम्न स्थानों पर किया जाना उचित रहता है-
(a) किसी फंक्शन के प्रारम्भ में.
(b) प्रोग्राम के प्रारम्भ में,
(c) वेरिएबल नेम निर्धारित करने वाली लाइन में वेरिएबलों स्थिति, क्षेत्र एवं उपयोग बताने के लिए।
प्रोग्रामिंग में टिप्पणियों का उपयोग कब और क्यों करें?
- यदि कार्यक्रम के विवरण के बारे में टिप्पणी प्रदान नहीं की जाती है तो एक बड़ा कोड पढ़ने वाला व्यक्ति दंग रह जाएगा।
- टिप्पणियाँ अधिक विवरण प्रदान करके कोड को अधिक पठनीय बनाने का एक तरीका है।
- टिप्पणियों में कोड को समझने योग्य बनाने के लिए एल्गोरिथम का विवरण शामिल हो सकता है।
- कोड के कुछ हिस्सों के निष्पादन को रोकने के लिए टिप्पणियों का उपयोग किया जा सकता है।
- // - Single line
- /**/ - Multi line
Single-line Comments
C में सिंगल लाइन कमेंट (//) डबल फॉरवर्ड स्लैश से शुरू होता है। यह पंक्ति के अंत तक विस्तृत होता है और हमें इसके अंत को निर्दिष्ट करने की आवश्यकता नहीं है।
Multi-line Comments
C में मल्टी लाइन टिप्पणी एक फ़ॉरवर्ड स्लैश और तारक (/*) से शुरू होती है और एक तारक और फ़ॉरवर्ड स्लैश (*/) के साथ समाप्त होती है। /* और */ के बीच कोई भी पाठ एक टिप्पणी के रूप में माना जाता है और संकलक द्वारा अनदेखा किया जाता है।