Re: Calculate percentages

From: Brian K. White (brian_at_aljex.com)
Date: 10/24/05

  • Next message: Bill Vermillion: "Re: Calculate percentages"
    Date: 24 Oct 2005 16:39:19 -0400
    
    

    ----- Original Message -----
    From: "Jean-Pierre Radley" <jpr@jpr.com>
    Newsgroups: comp.unix.sco.misc
    To: <distro@jpr.com>
    Sent: Sunday, October 23, 2005 6:10 PM
    Subject: Re: Calculate percentages

    > Dion typed (on Sun, Oct 23, 2005 at 01:33:13PM -0700):
    > | I am a beginner in UNIX and I want to write a shell script calculating
    > | the proportion of one-line comments in any C++ program. Could anyone
    > | help me please? Thanks!
    >
    >
    > I daresay you haven't the least interest or purpose in knowing how many
    > comments in a program are one-liners.
    >
    > Occam's razor tells me that your instructor has asked you to write such a
    > script. Does your instructor approve of your getting help from us?
    > Would that affect your grade?

    Well, to be honest,

    There is a comment syntax for single lines that is valid in c++ that is not
    valid in c.
    And it would be both a simple "get report", and possibly legitimately
    useful, to find only those lines that would be invalid c syntax.

    But I won't divulge any more hint than I already have in case you are right,
    because it looks that way to me too.
    Besides, I've already seen his next post and someone apparently never
    figured out the kindergarden basic life lesson yet that you catch more flies
    with honey.
    Maybe he feels this makes me an jerk, but in the end, I know the answer, and
    he's dissuaded me from being generous with it. ;)

    I only wish Tony hadn't sabotaged our plot to keep him in the dark forever
    muhahahahaha.....

    Brian K. White -- brian@aljex.com -- http://www.aljex.com/bkw/
    +++++[>+++[>+++++>+++++++<<-]<-]>>+.>.+++++.+++++++.-.[>+<---]>++.
    filePro BBx Linux SCO FreeBSD #callahans Satriani Filk!


  • Next message: Bill Vermillion: "Re: Calculate percentages"

    Relevant Pages

    • Re: Calculate percentages
      ... >>| I am a beginner in UNIX and I want to write a shell script calculating ... Does your instructor approve of your getting help from us? ... Tony Lawrence ...
      (comp.unix.sco.misc)
    • Re: Calculate percentages
      ... | I am a beginner in UNIX and I want to write a shell script calculating ... | the proportion of one-line comments in any C++ program. ... Does your instructor approve of your getting help from us? ...
      (comp.unix.sco.misc)
    • Re: Calculate percentages
      ... >> | I am a beginner in UNIX and I want to write a shell script calculating ... to find only those lines that would be invalid c syntax. ... You can kill a lot more with Black Flag. ... Bill Vermillion - bv @ wjv. ...
      (comp.unix.sco.misc)
    • Re: Calculate percentages
      ... > I am a beginner in UNIX and I want to write a shell script calculating ... Please don't multi-post, either pick one newsgroup or use cross-posting ...
      (comp.unix.admin)
    • Re: Calculate percentages
      ... > I am a beginner in UNIX and I want to write a shell script calculating ... Please don't multi-post, either pick one newsgroup or use cross-posting ...
      (comp.unix.shell)