less is more? Is more less? I'm so confused

28,638

Solution 1

more is a basic pager, which allows you to scroll downwards, one page at a time. Only downwards.

less is also a pager, but has addition functionality to scroll upwards and downwards through the input, in addition to several other extensions.

So, yes. less is more, and more is less. Another common idiom (according to the wiki entry) is "less is more, more or less." The name comes from the fact that the author (Mark Nudelman) essentially wanted a program that was "backwards more" -- The opposite of more, is less.

Solution 2

I find less a bit more friendly than more because you can use the arrow keys to stroll through the file. more only scrolls screen by screen (by default).

Solution 3

Other that it allows more scrolling features, less also doesn't need to read the whole file, i.e. it loads files faster than more

Solution 4

Another difference between more and less, is that more leaves the (last page of the) output on the shell, while less leaves the shell clean.

Sometimes you might prefer one over the other. For example, if you need to copy-paste from the file, more can be better. However, in other cases you might prefer the 'cleaner' approach of less.

Share:
28,638

Related videos on Youtube

user541686
Author by

user541686

Updated on September 18, 2022

Comments

  • user541686
    user541686 over 1 year

    When I first heard their names, I got really confused when I tried to guess what these tools might do, I thought I'd misheard something.

    What's the difference between more and less, i.e. why should I choose one over the other?
    They both seem to do the same thing...

    Also, why are they named like that in the first place?

    • DrColossos
      DrColossos almost 13 years
      Wait until you find out about most! It's just like more and less but it supports colors too!
    • user541686
      user541686 almost 13 years
      o_O you're joking right?
    • new123456
      new123456 almost 13 years
      @Mehrdad No.
    • user541686
      user541686 almost 13 years
      @new123456: lol Why settle for less?...
    • ctype.h
      ctype.h over 12 years
      less is more than more!
  • user541686
    user541686 almost 13 years
    +1 cool, thanks. Any idea why more was named more, btw?
  • user1984103
    user1984103 almost 13 years
    @Mehrdad All I have to go on is the wiki entry, which states "The name came from the joke of doing 'backwards more.'"
  • user1984103
    user1984103 almost 13 years
    @Mehrdad I just realized I misread your comment-- I have no clue why more is called "more", but I would suspect that it's because all the program originally did was accept input and display -- More -- at the bottom of the screen if there was more.
  • Stephanie
    Stephanie almost 13 years
    more came well before less, and was named for the simple purpose that it let you handle "more" output than would fit on screen.
  • Daniel R Hicks
    Daniel R Hicks about 12 years
    True, more or less.
  • Kevin Versfeld
    Kevin Versfeld over 9 years
    To add confusion...what about the 'most' pager program.
  • Canadian Luke
    Canadian Luke over 9 years
    ... And you can search with /
  • cowlinator
    cowlinator over 5 years
    Which should you use? It doesn't matter, more or less.
  • torek
    torek about 4 years
    Less's behavior on small inputs and its use of the alternate screen is configurable (-F and -X respectively).