What does “^L” mean in C?












33















For example, main in src/hello.c in the GNU Hello package ends like this:



   exit (EXIT_SUCCESS);
}
^L









share|improve this question




















  • 12





    It means that the program's done ... to L with it!

    – Hot Licks
    Mar 17 at 20:27











  • I'm wondering though if that is an actual FF and the editor simply shows it like ^L, or if it's the characters "^L". If I were an editor, I'd show an FF like "♀" or "␌".

    – Mr Lister
    Mar 18 at 7:55













  • @MrLister: Then you would wonder if it's an actual FF or the characters ♀ or ␌. ;-)

    – tomasz
    Mar 19 at 12:28











  • ^L is a Control-L or ASCII FORM FEED, to eject the page. The C compiler normally ignores it, and the editor shows it as shown in your sample.

    – Luis Colorado
    Mar 20 at 6:29











  • Possible duplicate of Escape sequence f - form feed - what exactly is it?

    – phuclv
    Mar 21 at 1:49
















33















For example, main in src/hello.c in the GNU Hello package ends like this:



   exit (EXIT_SUCCESS);
}
^L









share|improve this question




















  • 12





    It means that the program's done ... to L with it!

    – Hot Licks
    Mar 17 at 20:27











  • I'm wondering though if that is an actual FF and the editor simply shows it like ^L, or if it's the characters "^L". If I were an editor, I'd show an FF like "♀" or "␌".

    – Mr Lister
    Mar 18 at 7:55













  • @MrLister: Then you would wonder if it's an actual FF or the characters ♀ or ␌. ;-)

    – tomasz
    Mar 19 at 12:28











  • ^L is a Control-L or ASCII FORM FEED, to eject the page. The C compiler normally ignores it, and the editor shows it as shown in your sample.

    – Luis Colorado
    Mar 20 at 6:29











  • Possible duplicate of Escape sequence f - form feed - what exactly is it?

    – phuclv
    Mar 21 at 1:49














33












33








33


5






For example, main in src/hello.c in the GNU Hello package ends like this:



   exit (EXIT_SUCCESS);
}
^L









share|improve this question
















For example, main in src/hello.c in the GNU Hello package ends like this:



   exit (EXIT_SUCCESS);
}
^L






c






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 17 at 19:24









Peter Mortensen

13.8k1987113




13.8k1987113










asked Mar 17 at 4:13









Sean LetendreSean Letendre

5311722




5311722








  • 12





    It means that the program's done ... to L with it!

    – Hot Licks
    Mar 17 at 20:27











  • I'm wondering though if that is an actual FF and the editor simply shows it like ^L, or if it's the characters "^L". If I were an editor, I'd show an FF like "♀" or "␌".

    – Mr Lister
    Mar 18 at 7:55













  • @MrLister: Then you would wonder if it's an actual FF or the characters ♀ or ␌. ;-)

    – tomasz
    Mar 19 at 12:28











  • ^L is a Control-L or ASCII FORM FEED, to eject the page. The C compiler normally ignores it, and the editor shows it as shown in your sample.

    – Luis Colorado
    Mar 20 at 6:29











  • Possible duplicate of Escape sequence f - form feed - what exactly is it?

    – phuclv
    Mar 21 at 1:49














  • 12





    It means that the program's done ... to L with it!

    – Hot Licks
    Mar 17 at 20:27











  • I'm wondering though if that is an actual FF and the editor simply shows it like ^L, or if it's the characters "^L". If I were an editor, I'd show an FF like "♀" or "␌".

    – Mr Lister
    Mar 18 at 7:55













  • @MrLister: Then you would wonder if it's an actual FF or the characters ♀ or ␌. ;-)

    – tomasz
    Mar 19 at 12:28











  • ^L is a Control-L or ASCII FORM FEED, to eject the page. The C compiler normally ignores it, and the editor shows it as shown in your sample.

    – Luis Colorado
    Mar 20 at 6:29











  • Possible duplicate of Escape sequence f - form feed - what exactly is it?

    – phuclv
    Mar 21 at 1:49








12




12





It means that the program's done ... to L with it!

– Hot Licks
Mar 17 at 20:27





It means that the program's done ... to L with it!

– Hot Licks
Mar 17 at 20:27













I'm wondering though if that is an actual FF and the editor simply shows it like ^L, or if it's the characters "^L". If I were an editor, I'd show an FF like "♀" or "␌".

– Mr Lister
Mar 18 at 7:55







I'm wondering though if that is an actual FF and the editor simply shows it like ^L, or if it's the characters "^L". If I were an editor, I'd show an FF like "♀" or "␌".

– Mr Lister
Mar 18 at 7:55















@MrLister: Then you would wonder if it's an actual FF or the characters ♀ or ␌. ;-)

– tomasz
Mar 19 at 12:28





@MrLister: Then you would wonder if it's an actual FF or the characters ♀ or ␌. ;-)

– tomasz
Mar 19 at 12:28













^L is a Control-L or ASCII FORM FEED, to eject the page. The C compiler normally ignores it, and the editor shows it as shown in your sample.

– Luis Colorado
Mar 20 at 6:29





^L is a Control-L or ASCII FORM FEED, to eject the page. The C compiler normally ignores it, and the editor shows it as shown in your sample.

– Luis Colorado
Mar 20 at 6:29













Possible duplicate of Escape sequence f - form feed - what exactly is it?

– phuclv
Mar 21 at 1:49





Possible duplicate of Escape sequence f - form feed - what exactly is it?

– phuclv
Mar 21 at 1:49












2 Answers
2






active

oldest

votes


















58














Literally, it's a page break ("form feed") character. The compiler treats it as ordinary whitespace. But it's very useful for printing source code - it starts a new page (for example, use ^L between functions to force each call to get its own page).



In Vim/vi based editors, you can insert such a character within edit mode by typing Ctrl + V followed by Ctrl + L. It will look like ^L in the editor, but it's actually just one character (ASCII value: 12 or 0x0C).






share|improve this answer





















  • 7





    If you would print the source code on paper, the printer would… start a new page.

    – Hermann
    Mar 17 at 18:11






  • 7





    Literally this

    – selbie
    Mar 17 at 18:11






  • 13





    @Croll Obviously that's been a short life. You've never had to deal with hundreds of pages of listing s from a line printer. You'd use it all right.

    – user207421
    Mar 17 at 19:49






  • 4





    @Croll Well, it's hardly the first time someone's used whitespace to make code format nicely, is it?

    – naomimyselfandi
    Mar 17 at 19:53






  • 2





    @user207421 - I can remember the good ole days, when, if the compiler wasn't smart enough to automatically do it at the start of a procedure you'd insert @eject or some such, to get to the top of the next neatly folded page of form-feed paper. Made reviewing code much easier.

    – Hot Licks
    Mar 17 at 20:30



















1














it is also called form feed.It is a page-breaking ASCII control character. It forces the printer to eject the current page and to continue printing at the top of another. It will also cause a carriage return. The form feed character code is defined as 12
(0xC in hexadecimal)






share|improve this answer























    Your Answer






    StackExchange.ifUsing("editor", function () {
    StackExchange.using("externalEditor", function () {
    StackExchange.using("snippets", function () {
    StackExchange.snippets.init();
    });
    });
    }, "code-snippets");

    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "1"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55203770%2fwhat-does-l-mean-in-c%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    58














    Literally, it's a page break ("form feed") character. The compiler treats it as ordinary whitespace. But it's very useful for printing source code - it starts a new page (for example, use ^L between functions to force each call to get its own page).



    In Vim/vi based editors, you can insert such a character within edit mode by typing Ctrl + V followed by Ctrl + L. It will look like ^L in the editor, but it's actually just one character (ASCII value: 12 or 0x0C).






    share|improve this answer





















    • 7





      If you would print the source code on paper, the printer would… start a new page.

      – Hermann
      Mar 17 at 18:11






    • 7





      Literally this

      – selbie
      Mar 17 at 18:11






    • 13





      @Croll Obviously that's been a short life. You've never had to deal with hundreds of pages of listing s from a line printer. You'd use it all right.

      – user207421
      Mar 17 at 19:49






    • 4





      @Croll Well, it's hardly the first time someone's used whitespace to make code format nicely, is it?

      – naomimyselfandi
      Mar 17 at 19:53






    • 2





      @user207421 - I can remember the good ole days, when, if the compiler wasn't smart enough to automatically do it at the start of a procedure you'd insert @eject or some such, to get to the top of the next neatly folded page of form-feed paper. Made reviewing code much easier.

      – Hot Licks
      Mar 17 at 20:30
















    58














    Literally, it's a page break ("form feed") character. The compiler treats it as ordinary whitespace. But it's very useful for printing source code - it starts a new page (for example, use ^L between functions to force each call to get its own page).



    In Vim/vi based editors, you can insert such a character within edit mode by typing Ctrl + V followed by Ctrl + L. It will look like ^L in the editor, but it's actually just one character (ASCII value: 12 or 0x0C).






    share|improve this answer





















    • 7





      If you would print the source code on paper, the printer would… start a new page.

      – Hermann
      Mar 17 at 18:11






    • 7





      Literally this

      – selbie
      Mar 17 at 18:11






    • 13





      @Croll Obviously that's been a short life. You've never had to deal with hundreds of pages of listing s from a line printer. You'd use it all right.

      – user207421
      Mar 17 at 19:49






    • 4





      @Croll Well, it's hardly the first time someone's used whitespace to make code format nicely, is it?

      – naomimyselfandi
      Mar 17 at 19:53






    • 2





      @user207421 - I can remember the good ole days, when, if the compiler wasn't smart enough to automatically do it at the start of a procedure you'd insert @eject or some such, to get to the top of the next neatly folded page of form-feed paper. Made reviewing code much easier.

      – Hot Licks
      Mar 17 at 20:30














    58












    58








    58







    Literally, it's a page break ("form feed") character. The compiler treats it as ordinary whitespace. But it's very useful for printing source code - it starts a new page (for example, use ^L between functions to force each call to get its own page).



    In Vim/vi based editors, you can insert such a character within edit mode by typing Ctrl + V followed by Ctrl + L. It will look like ^L in the editor, but it's actually just one character (ASCII value: 12 or 0x0C).






    share|improve this answer















    Literally, it's a page break ("form feed") character. The compiler treats it as ordinary whitespace. But it's very useful for printing source code - it starts a new page (for example, use ^L between functions to force each call to get its own page).



    In Vim/vi based editors, you can insert such a character within edit mode by typing Ctrl + V followed by Ctrl + L. It will look like ^L in the editor, but it's actually just one character (ASCII value: 12 or 0x0C).







    share|improve this answer














    share|improve this answer



    share|improve this answer








    edited Mar 17 at 19:26









    Peter Mortensen

    13.8k1987113




    13.8k1987113










    answered Mar 17 at 4:16









    selbieselbie

    56.7k1064124




    56.7k1064124








    • 7





      If you would print the source code on paper, the printer would… start a new page.

      – Hermann
      Mar 17 at 18:11






    • 7





      Literally this

      – selbie
      Mar 17 at 18:11






    • 13





      @Croll Obviously that's been a short life. You've never had to deal with hundreds of pages of listing s from a line printer. You'd use it all right.

      – user207421
      Mar 17 at 19:49






    • 4





      @Croll Well, it's hardly the first time someone's used whitespace to make code format nicely, is it?

      – naomimyselfandi
      Mar 17 at 19:53






    • 2





      @user207421 - I can remember the good ole days, when, if the compiler wasn't smart enough to automatically do it at the start of a procedure you'd insert @eject or some such, to get to the top of the next neatly folded page of form-feed paper. Made reviewing code much easier.

      – Hot Licks
      Mar 17 at 20:30














    • 7





      If you would print the source code on paper, the printer would… start a new page.

      – Hermann
      Mar 17 at 18:11






    • 7





      Literally this

      – selbie
      Mar 17 at 18:11






    • 13





      @Croll Obviously that's been a short life. You've never had to deal with hundreds of pages of listing s from a line printer. You'd use it all right.

      – user207421
      Mar 17 at 19:49






    • 4





      @Croll Well, it's hardly the first time someone's used whitespace to make code format nicely, is it?

      – naomimyselfandi
      Mar 17 at 19:53






    • 2





      @user207421 - I can remember the good ole days, when, if the compiler wasn't smart enough to automatically do it at the start of a procedure you'd insert @eject or some such, to get to the top of the next neatly folded page of form-feed paper. Made reviewing code much easier.

      – Hot Licks
      Mar 17 at 20:30








    7




    7





    If you would print the source code on paper, the printer would… start a new page.

    – Hermann
    Mar 17 at 18:11





    If you would print the source code on paper, the printer would… start a new page.

    – Hermann
    Mar 17 at 18:11




    7




    7





    Literally this

    – selbie
    Mar 17 at 18:11





    Literally this

    – selbie
    Mar 17 at 18:11




    13




    13





    @Croll Obviously that's been a short life. You've never had to deal with hundreds of pages of listing s from a line printer. You'd use it all right.

    – user207421
    Mar 17 at 19:49





    @Croll Obviously that's been a short life. You've never had to deal with hundreds of pages of listing s from a line printer. You'd use it all right.

    – user207421
    Mar 17 at 19:49




    4




    4





    @Croll Well, it's hardly the first time someone's used whitespace to make code format nicely, is it?

    – naomimyselfandi
    Mar 17 at 19:53





    @Croll Well, it's hardly the first time someone's used whitespace to make code format nicely, is it?

    – naomimyselfandi
    Mar 17 at 19:53




    2




    2





    @user207421 - I can remember the good ole days, when, if the compiler wasn't smart enough to automatically do it at the start of a procedure you'd insert @eject or some such, to get to the top of the next neatly folded page of form-feed paper. Made reviewing code much easier.

    – Hot Licks
    Mar 17 at 20:30





    @user207421 - I can remember the good ole days, when, if the compiler wasn't smart enough to automatically do it at the start of a procedure you'd insert @eject or some such, to get to the top of the next neatly folded page of form-feed paper. Made reviewing code much easier.

    – Hot Licks
    Mar 17 at 20:30













    1














    it is also called form feed.It is a page-breaking ASCII control character. It forces the printer to eject the current page and to continue printing at the top of another. It will also cause a carriage return. The form feed character code is defined as 12
    (0xC in hexadecimal)






    share|improve this answer




























      1














      it is also called form feed.It is a page-breaking ASCII control character. It forces the printer to eject the current page and to continue printing at the top of another. It will also cause a carriage return. The form feed character code is defined as 12
      (0xC in hexadecimal)






      share|improve this answer


























        1












        1








        1







        it is also called form feed.It is a page-breaking ASCII control character. It forces the printer to eject the current page and to continue printing at the top of another. It will also cause a carriage return. The form feed character code is defined as 12
        (0xC in hexadecimal)






        share|improve this answer













        it is also called form feed.It is a page-breaking ASCII control character. It forces the printer to eject the current page and to continue printing at the top of another. It will also cause a carriage return. The form feed character code is defined as 12
        (0xC in hexadecimal)







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Mar 22 at 13:42









        dark_3nergydark_3nergy

        628




        628






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55203770%2fwhat-does-l-mean-in-c%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            How to change which sound is reproduced for terminal bell?

            Title Spacing in Bjornstrup Chapter, Removing Chapter Number From Contents

            Can I use Tabulator js library in my java Spring + Thymeleaf project?