Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    Regular Coder
    Join Date
    Nov 2002
    Posts
    180
    Thanks
    0
    Thanked 0 Times in 0 Posts

    question about java

    what is meaning of using:
    \f or form feed
    and:
    \r or carriage return?

  • #2
    Regular Coder
    Join Date
    Feb 2003
    Location
    California
    Posts
    925
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I don't know if you would need them in code but they can be used for comparison with user input.


    Jason

  • #3
    Regular Coder
    Join Date
    Nov 2002
    Posts
    180
    Thanks
    0
    Thanked 0 Times in 0 Posts
    we know that we can use special characters with the strings for many purpose like \n for new line, my question was: what for we use \f and \r?

  • #4
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    If you're writing to a printer then \f should exject the current page and \r allows overtyping. They were a lot more important in the past when much output was designed for paper and printers weren't graphic so to get underlined text you had to type the text, and then go back and type the underline separately.

  • #5
    Regular Coder
    Join Date
    Nov 2002
    Posts
    180
    Thanks
    0
    Thanked 0 Times in 0 Posts
    If you're writing to a printer then \f should exject the current page
    i didn't understand the meaning of exject?

  • #6
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Typo, exject should be eject. That is it stops printing on the current piece of paper and feeds in the next page.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •