missing a char

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Elijah Cardon

    #1

    missing a char

    1 1 1 1 1 1
    2 2 2 1 1 1
    3 3 3 1 1 1
    4 4 1 2 1 1
    5 5 2 2 1 1
    6 6 3 2 1 1
    7 7 1 3 1 1
    8 8 2 3 1 1
    9 9 3 3 1 1
    10 10 1 1 2 1
    11 11 2 1 2 1
    12 12 3 1 2 1
    13 13 1 2 2 1
    14 14 2 2 2 1
    15 15 3 2 2 1
    16 16 1 3 2 1
    17 17 2 3 2 1
    18 18 3 3 2 1
    19 19 1 1 3 1
    20 20 2 1 3 1
    21 21 3 1 3 1
    22 22 1 2 3 1
    23 23 2 2 3 1
    24 24 3 2 3 1
    25 25 1 3 3 1
    26 26 2 3 3 1
    27 27 3 3 3 1
    28 28 1 1 1 2
    29 29 2 1 1 2
    30 30 3 1 1 2
    31 31 1 2 1 2
    32 32 2 2 1 2
    33 33 3 2 1 2
    34 34 1 3 1 2
    35 35 2 3 1 2
    36 36 3 3 1 2
    37 37 1 1 2 2
    38 38 2 1 2 2
    39 39 3 1 2 2
    40 40 1 2 2 2
    41 41 2 2 2 2
    42 42 3 2 2 2
    43 43 1 3 2 2
    44 44 2 3 2 2
    45 45 3 3 2 2
    46 46 1 1 3 2
    47 47 2 1 3 2
    48 48 3 1 3 2
    49 49 1 2 3 2
    50 50 2 2 3 2
    51 51 3 2 3 2
    52 52 1 3 3 2
    53 53 2 3 3 2
    54 54 3 3 3 2
    55 55 1 1 1 3
    56 56 2 1 1 3
    57 57 3 1 1 3
    58 58 1 2 1 3
    59 59 2 2 1 3
    60 60 3 2 1 3
    61 61 1 3 1 3
    62 62 2 3 1 3
    63 63 3 3 1 3
    64 64 1 1 2 3
    65 65 2 1 2 3
    66 66 3 1 2 3
    67 67 1 2 2 3
    68 68 2 2 2 3
    69 69 3 2 2 3
    70 70 1 3 2 3
    71 71 2 3 2 3
    72 72 3 3 2 3
    73 73 1 1 3 3
    74 74 2 1 3 3
    75 75 3 1 3 3
    76 76 1 2 3 3
    77 77 2 2 3 3
    78 78 3 2 3 3
    79 79 1 3 3 3
    80 80 2 3 3 3
    81 81 3 3 3 3
    EOF
    This longish post is crossposted to comp.lang.c and to comp.lang.fortr an .
    I believe that I have simulated setting the follow-ups by writing the
    message on notepad and posting as if the other ng didn't exist.

    I redirected this output to a text file that my OS believes is 3078 bytes in
    length. There are six fields of six chars and 81 lines. 36 times 81 is
    2916. Add in 81 carriage returns and you have 2997. Besides missing good
    vision, I seem to be missing a char on every line. Ideas? EC


  • Richard Heathfield

    #2
    Re: missing a char

    Elijah Cardon said:

    <snip>
    I redirected this output to a text file that my OS believes is 3078 bytes
    in
    length. There are six fields of six chars and 81 lines. 36 times 81 is
    2916. Add in 81 carriage returns and you have 2997. Besides missing good
    vision, I seem to be missing a char on every line. Ideas? EC
    You forgot newlines. Each line comprises:

    six fields of six characters = 36
    one carriage return '\r' = 1
    one newline '\n' = 1
    ----
    38

    38 * 81 = 3078

    --
    Richard Heathfield
    "Usenet is a strange place" - dmr 29/7/1999

    email: rjh at above domain (but drop the www, obviously)

    Comment

    • mark_bluemel@pobox.com

      #3
      Re: missing a char


      Elijah Cardon wrote:
      1 1 1 1 1 1
      81 81 3 3 3 3
      EOF
      This longish post is crossposted to comp.lang.c and to comp.lang.fortr an .
      Why?
      I believe that I have simulated setting the follow-ups by writing the
      message on notepad and posting as if the other ng didn't exist.
      Why do we need to know this?
      I redirected this output to a text file that my OS believes is 3078 bytes in
      length. There are six fields of six chars and 81 lines. 36 times 81 is
      2916. Add in 81 carriage returns and you have 2997. Besides missing good
      vision, I seem to be missing a char on every line. Ideas? EC
      1) learn about the text file format which applies to your OS
      2) find out how to dump a file in hexadecimal format (or write a small
      program to do the job)

      Comment

      • Elijah Cardon

        #4
        Re: missing a char


        "Richard Heathfield" <invalid@invali d.invalidwrote in message
        news:rt6dne2bP9 WSR7nYnZ2dnUVZ8 tSdnZ2d@bt.com. ..
        Elijah Cardon said:
        >
        <snip>
        >
        >I redirected this output to a text file that my OS believes is 3078 bytes
        >in
        >length. There are six fields of six chars and 81 lines. 36 times 81 is
        >2916. Add in 81 carriage returns and you have 2997. Besides missing
        >good
        >vision, I seem to be missing a char on every line. Ideas? EC
        >
        You forgot newlines. Each line comprises:
        >
        six fields of six characters = 36
        one carriage return '\r' = 1
        one newline '\n' = 1
        ----
        38
        >
        38 * 81 = 3078
        Did you rely on methods that lie outside the realm of the C programming
        language to determine this? Mr. Heathfield claims he can't program on the
        fly, which is as large an exxageration there can be before it is a lie. My
        guess is that he "knew" this, which is an odd thing to know about somebody
        else's data. Comes from experience.

        I further guess that if you set CBfalconer's ggets on the output, the unseen
        chars would unpalimpsest. How does a person set the follow-ups to a
        cross-post? EC


        Comment

        • Richard Heathfield

          #5
          Re: missing a char

          Elijah Cardon said:
          Did you rely on methods that lie outside the realm of the C programming
          language to determine this?
          If you want to play games, please do it elsewhere. You asked a question, and
          got the right answer. If you don't like the right answer, don't ask the
          question.

          --
          Richard Heathfield
          "Usenet is a strange place" - dmr 29/7/1999

          email: rjh at above domain (but drop the www, obviously)

          Comment

          • Default User

            #6
            Re: missing a char

            Elijah Cardon wrote:

            This longish post is crossposted to comp.lang.c and to
            comp.lang.fortr an .
            No, it wasn't. You may have posted it to clf as well, but that's not a
            cross-post.




            Brian

            Comment

            • Rod Pemberton

              #7
              Re: missing a char


              "Elijah Cardon" <invalid@invali d.netwrote in message
              news:12ia1pea8o d559e@corp.supe rnews.com...
              >
              "Richard Heathfield" <invalid@invali d.invalidwrote in message
              news:rt6dne2bP9 WSR7nYnZ2dnUVZ8 tSdnZ2d@bt.com. ..
              Elijah Cardon said:

              <snip>
              I redirected this output to a text file that my OS believes is 3078
              bytes
              in
              length. There are six fields of six chars and 81 lines. 36 times 81
              is
              2916. Add in 81 carriage returns and you have 2997. Besides missing
              good
              vision, I seem to be missing a char on every line. Ideas? EC
              You forgot newlines. Each line comprises:
              <snip>
              38 * 81 = 3078
              Did you rely on methods that lie outside the realm of the C programming
              language to determine this?
              Yes, he did. But, __unfortunately __, he didn't have to. This was snipped
              from working code of mine...(so you'll have to add the includes,etc... ):

              #define NLSZ 10
              FILE *nlf;
              unsigned char nl[NLSZ],nl_sz=0;

              /* determine actual binary values for text newline */
              memset(nl,0,NLS Z);
              nlf=fopen("newl ine0.xxx","wt") ;
              fprintf(nlf,"\n ");
              fclose(nlf);
              nlf=fopen("newl ine0.xxx","rb") ;
              while((!feof(nl f))&&(nl_sz<NLS Z))
              {
              nl[nl_sz++]=fgetc(nlf);
              }
              nl_sz--;
              nl[nl_sz]='\0';
              fclose(nlf);
              remove("newline 0.xxx");
              Mr. Heathfield claims he can't program on the
              fly, which is as large an exxageration[sic] there can be before it is a
              lie. My
              guess is that he "knew" this, which is an odd thing to know about somebody
              else's data. Comes from experience.
              >
              Yes, he "knew" this.

              What's surprising is that he didn't (as he has done in the past) describe
              common ASCII return sequences: cr, lf, crlf. And, he didn't bring up EBCDIC
              or DEC VMS return sequence. And, he didn't bring up the fact that EBCDIC
              isn't standardized, or the fact that there are at least 8 common variants of
              EBCDIC, or the fact that HP, AT&T, POSIX, and IBM (5) all have variants, or
              the fact that there 82 invariant character positions and 13 variant
              positions in EBCDIC. Etc...
              I further guess that if you set CBfalconer's ggets on the output, the
              unseen
              chars would unpalimpsest.
              Although "palimpsest " is used in a very unusual manner and the F in
              CBFalconer is capitalized, it still deservers a hearty "hehe"... :-) Yes,
              CBFalconer's code is... Well, all you have to do is compare his strlcat()
              and strlcpy() with Russ Albery's Public Domain INN versions...
              How does a person set the follow-ups to a
              cross-post? EC
              >
              Ignoring the fact that you didn't "cross-post," but "multi-posted," there
              should be a header line for it when composing your email for nntp. The line
              will automatically redirect any replies to that _specific_ post to the
              followup newsgroup. It doesn't redirect the entire thread. You should
              always check to make sure someone didn't change the sent to newsgroups on
              you, and you many need to reset them before you send your reply. It may be
              an advanced feature... The line for MS Outlook is called: "Followup-To",
              and it should be at the same place where lines like "News Server",
              "Newsgroups ", "CC", "Reply-To" are. So, since I set the follows for this
              message to "alt.comp.lang. c", anyone replying to this message should see
              "alt.comp.lang. c" in the "Newsgroups " line instead of "comp.lang. c". Try
              replying to this message.

              :-)


              Rod Pemberton


              Comment

              • Lane Straatman

                #8
                Re: missing a char


                "Rod Pemberton" <do_not_have@bi tfoad.cmmwrote in message
                news:eg54e9$rot $1@main.corriga .net...
                >
                "Elijah Cardon" <invalid@invali d.netwrote in message
                news:12ia1pea8o d559e@corp.supe rnews.com...
                >>
                >"Richard Heathfield" <invalid@invali d.invalidwrote in message
                >news:rt6dne2bP 9WSR7nYnZ2dnUVZ 8tSdnZ2d@bt.com ...
                Elijah Cardon said:
                >
                <snip>
                >
                >I redirected this output to a text file that my OS believes is 3078
                bytes
                >in
                >length. There are six fields of six chars and 81 lines. 36 times 81
                is
                >2916. Add in 81 carriage returns and you have 2997. Besides missing
                >good
                >vision, I seem to be missing a char on every line. Ideas? EC
                >
                You forgot newlines. Each line comprises:
                >
                <snip>
                38 * 81 = 3078
                >
                >Did you rely on methods that lie outside the realm of the C programming
                >language to determine this?
                >
                Yes, he did. But, __unfortunately __, he didn't have to. This was snipped
                from working code of mine...(so you'll have to add the includes,etc... ):
                >
                #define NLSZ 10
                FILE *nlf;
                unsigned char nl[NLSZ],nl_sz=0;
                >
                /* determine actual binary values for text newline */
                memset(nl,0,NLS Z);
                nlf=fopen("newl ine0.xxx","wt") ;
                fprintf(nlf,"\n ");
                fclose(nlf);
                nlf=fopen("newl ine0.xxx","rb") ;
                while((!feof(nl f))&&(nl_sz<NLS Z))
                {
                nl[nl_sz++]=fgetc(nlf);
                }
                nl_sz--;
                nl[nl_sz]='\0';
                fclose(nlf);
                remove("newline 0.xxx");
                I'll feed this to my compiler when she gets hungry.
                What's surprising is that he didn't (as he has done in the past) describe
                common ASCII return sequences: cr, lf, crlf. And, he didn't bring up
                EBCDIC
                or DEC VMS return sequence. And, he didn't bring up the fact that EBCDIC
                isn't standardized, or the fact that there are at least 8 common variants
                of
                EBCDIC, or the fact that HP, AT&T, POSIX, and IBM (5) all have variants,
                or
                the fact that there 82 invariant character positions and 13 variant
                positions in EBCDIC. Etc...
                A merciful act.
                >I further guess that if you set CBfalconer's ggets on the output, the
                unseen
                >chars would unpalimpsest.
                >
                Although "palimpsest " is used in a very unusual manner and the F in
                CBFalconer is capitalized, it still deservers a hearty "hehe"... :-) Yes,
                CBFalconer's code is... Well, all you have to do is compare his strlcat()
                and strlcpy() with Russ Albery's Public Domain INN versions...
                >
                >How does a person set the follow-ups to a
                >cross-post? EC
                >>
                >
                Ignoring the fact that you didn't "cross-post," but "multi-posted," there
                should be a header line for it when composing your email for nntp. The
                line
                will automatically redirect any replies to that _specific_ post to the
                followup newsgroup. It doesn't redirect the entire thread. You
                should
                always check to make sure someone didn't change the sent to newsgroups on
                you, and you many need to reset them before you send your reply. It may
                be
                an advanced feature... The line for MS Outlook is called: "Followup-To",
                and it should be at the same place where lines like "News Server",
                "Newsgroups ", "CC", "Reply-To" are. So, since I set the follows for this
                message to "alt.comp.lang. c", anyone replying to this message should see
                "alt.comp.lang. c" in the "Newsgroups " line instead of "comp.lang. c". Try
                replying to this message.
                dankenstein, lane


                Comment

                • Lane Straatman

                  #9
                  Re: missing a char


                  <mark_bluemel@p obox.comwrote in message
                  news:1160053847 .607283.295270@ m73g2000cwd.goo glegroups.com.. .
                  >
                  Elijah Cardon wrote:
                  >
                  >1 1 1 1 1 1
                  > 81 81 3 3 3 3
                  >EOF
                  >This longish post is crossposted to comp.lang.c and to comp.lang.fortr an
                  >.
                  >
                  Why?
                  When I'm missing something, it bugs me. I don't like bugs. The cockroaches
                  here in River City I kill with impunity. Unfortunately, I'm running on MS
                  and chasing after a bug can turn into an Opus Magnum. Oops, did I say
                  'Jehovah'?
                  >I believe that I have simulated setting the follow-ups by writing the
                  >message on notepad and posting as if the other ng didn't exist.
                  >
                  Why do we need to know this?
                  See upthread.
                  >I redirected this output to a text file that my OS believes is 3078 bytes
                  >in
                  >length. There are six fields of six chars and 81 lines. 36 times 81 is
                  >2916. Add in 81 carriage returns and you have 2997. Besides missing
                  >good
                  >vision, I seem to be missing a char on every line. Ideas? EC
                  >
                  1) learn about the text file format which applies to your OS
                  2) find out how to dump a file in hexadecimal format (or write a small
                  program to do the job)
                  If you're on xp and programming in c, why would do something that you'd do
                  with the microwave you took out of the trash? LS


                  Comment

                  Working...