PC Review


Reply
Thread Tools Rate Thread

Binary operator >> (?)

 
 
Scossa
Guest
Posts: n/a
 
      18th Mar 2011
Hello,

I' apologize for my bad english......

Everyone know logical operator "=", ">", "<", ">=", "<=", but i found
that this operator ">>" in a function like CountIf()

=CountIf( A1:A30, ">>")

returns the numbures of cells that contain text.

But unlike others operators, if you try somthing like =A1>>A3 yuo
can't close edit.

I haven't found nothing in on-line Excel documentation about this.

Ideas???

Bye!
Scossa
 
Reply With Quote
 
 
 
 
joeu2004
Guest
Posts: n/a
 
      18th Mar 2011
On Mar 18, 12:37*am, Scossa <scossa...@gmail.com> wrote:
> i found that this operator ">>" in a function like CountIf()
> =CountIf( A1:A30, ">>")
> returns the numbures of cells that contain text.
>
> But unlike others operators, if you try somthing like
>*=A1>>A3 yuo can't close edit.


You are misinterpreting the COUNTIF parameter, understandably.

The first ">" is the comparison operator. The second ">" is the
character ">".

So COUNTIF(A1:A30,">>") counts all cells will text whose strings
compare greater than ">".

You can replace the second ">" with other characters (e.g. ">:") and
get the same result.

You can see things as COUNTIF does by putting =A1>">" into B1 and copy
down through B30.

What I do find odd is that ="2">">" returns TRUE. The ASCII code for
"2" is 50, and the ASCII code for ">" is 62.
 
Reply With Quote
 
Scossa
Guest
Posts: n/a
 
      18th Mar 2011
On 18 Mar, 09:46, Ron Rosenfeld <r...@nospam.net> wrote:
> On Fri, 18 Mar 2011 00:37:46 -0700 (PDT), Scossa <scossa...@gmail.com> wrote:
> >Hello,

>
> >I' apologize for my bad english......

>
> >Everyone know logical operator "=", ">", "<", ">=", "<=", but i found
> >that this operator ">>" in a function like CountIf()

>
> >=CountIf( A1:A30, ">>")

>
> >returns the numbures of cells that contain text.

>
> >But unlike others operators, if you try somthing like *=A1>>A3 yuo
> >can't close edit.

>
> >I haven't found nothing in on-line Excel documentation *about this.

>
> >Ideas???

>
> >Bye!
> >Scossa

>
> I do not believe that ">>" is an operator. *Rather it means <greater than> <the greater than sign>
>
> In other words, the first character is the operator; the second characteris the operand.
>
> If you enter a series of characters in column A, and then in column B enter
>
> * * * * =A1 > ">"
>
> and fill down, you will see that anything that evaluates to TRUE will be counted by your COUNTIF expression.- Nascondi testo citato
>
> - Mostra testo citato -



OK, tnks, the correct explanation is often the simplest.

Bye!
Scossa
 
Reply With Quote
 
Scossa
Guest
Posts: n/a
 
      18th Mar 2011
On 18 Mar, 09:47, joeu2004 <joeu2...@hotmail.com> wrote:
> On Mar 18, 12:37*am, Scossa <scossa...@gmail.com> wrote:
>
> > i found that this operator ">>" in a function like CountIf()
> > =CountIf( A1:A30, ">>")
> > returns the numbures of cells that contain text.

>
> > But unlike others operators, if you try somthing like
> >*=A1>>A3 yuo can't close edit.

>
> You are misinterpreting the COUNTIF parameter, understandably.
>
> The first ">" is the comparison operator. *The second ">" is the
> character ">".
>
> So COUNTIF(A1:A30,">>") counts all cells will text whose strings
> compare greater than ">".
>
> You can replace the second ">" with other characters (e.g. ">:") and
> get the same result.
>
> You can see things as COUNTIF does by putting =A1>">" into B1 and copy
> down through B30.
>
> What I do find odd is that ="2">">" returns TRUE. *The ASCII code for
> "2" is 50, and the ASCII code for ">" is 62.


OK, tnks, the correct explanation is often the simplest.

Bye!
Scossa
 
Reply With Quote
 
Dave Peterson
Guest
Posts: n/a
 
      18th Mar 2011
You got the explanation, but this is one reason I like this format:
=countif(a1:a30,">"&">")

or even
=countif(a1:a30,">"&999)

I think it makes it easier to see what's happening.

On 03/18/2011 02:37, Scossa wrote:
> Hello,
>
> I' apologize for my bad english......
>
> Everyone know logical operator "=", ">","<",">=", "<=", but i found
> that this operator ">>" in a function like CountIf()
>
> =CountIf( A1:A30, ">>")
>
> returns the numbures of cells that contain text.
>
> But unlike others operators, if you try somthing like =A1>>A3 yuo
> can't close edit.
>
> I haven't found nothing in on-line Excel documentation about this.
>
> Ideas???
>
> Bye!
> Scossa


--
Dave Peterson
 
Reply With Quote
 
Scossa
Guest
Posts: n/a
 
      18th Mar 2011
On 18 Mar, 13:31, Dave Peterson <peter...@XSPAMverizon.net> wrote:
> You got the explanation, but this is one reason I like this format:
> =countif(a1:a30,">"&">")
>
> or even
> =countif(a1:a30,">"&999)
>
> I think it makes it easier to see what's happening.
>
> On 03/18/2011 02:37, Scossa wrote:
>
>
>
>
>
> > Hello,

>
> > I' apologize for my bad english......

>
> > Everyone know logical operator "=", ">","<",">=", "<=", but i found
> > that this operator ">>" in a function like CountIf()

>
> > =CountIf( A1:A30, ">>")

>
> > returns the numbures of cells that contain text.

>
> > But unlike others operators, if you try somthing like *=A1>>A3 yuo
> > can't close edit.

>
> > I haven't found nothing in on-line Excel documentation *about this.

>
> > Ideas???

>
> > Bye!
> > Scossa

>
> --
> Dave Peterson- Nascondi testo citato
>
> - Mostra testo citato -


Ok, tnks.
 
Reply With Quote
 
joeu2004
Guest
Posts: n/a
 
      18th Mar 2011
On Mar 18, 4:42*am, Ron Rosenfeld <r...@nospam.net> wrote:
> On Fri, 18 Mar 2011 01:47:28 -0700 (PDT), joeu2004 <joeu2...@hotmail.com>wrote:
> >What I do find odd is that ="2">">" returns TRUE.
> >*The ASCII code for "2" is 50, and the ASCII code
> > for ">" is 62.

>
> I'm sure you also noticed that the number 2 returns false
> when stored as a number.


I do not get your point, if you are trying to explain what I
observed. Perhaps you could elaborate, speaking directly to my
example.

=2>">" returns FALSE because numbers are always considered less than
text, based on the collating sequence described for VLOOKUP et al.

But I typed ="2">">". I am comparing text literal to text literal.
No references to cells with formulas. And Excel is treating "2"
different from 2 in that context, as evidenced by the difference in
comparison results.

I expect that comparision to follow the ASCII collating sequence,
except that lowercase and uppercase alpha are treated the same. That
is (written mathematically):

"!" < "/" < "0" < "9" < ":" < "@" < "A" < "Z"

I cannot say where __I__ would expect "[" and "{" to fit into the
collating sequence because I do not know whether uppercase alpha is
treated as lowercase alpha or vice versa.

If you can provide a pointer to Microsoft documentation about the
collating sequence of individual text characters in comparisons, that
would be helpful. I have tried a few Help searches, to no avail.
 
Reply With Quote
 
joeu2004
Guest
Posts: n/a
 
      18th Mar 2011
On Mar 18, 3:42*pm, Ron Rosenfeld <r...@nospam.net> wrote:
> In Excel 2007, the relevant HELP topic is "Default sort
> orders". I found it by searching for "sort order" on HELP.


Aha! Yes, I find the same Help entry in XL2003. Thanks for that.

But according to the XL2003 "sort order" help page:

----- begin quote
Text and text that includes numbers are sorted in the
following order:
0 1 2 3 4 5 6 7 8 9 (space) ! " # $ % & ( ) * , . / :
; ? @ [ \ ] ^ _ ` { | } ~ + < = > A B C D E F G H I J
K L M N O P Q R S T U V W X Y Z
----- end quote

Clearly, ="A">"Z" should and does return FALSE. So the table is in
ascending order.

So I still find it odd that ="2">">" returns TRUE, based on the above
table.
 
Reply With Quote
 
joeu2004
Guest
Posts: n/a
 
      19th Mar 2011
On Mar 18, 3:52*pm, joeu2004 <joeu2...@hotmail.com> wrote:
> But according to the XL2003 "sort order" help page:
> ----- begin quote
> Text and text that includes numbers are sorted in the
> following order:
> 0 1 2 3 4 5 6 7 8 9 (space) ! " # $ % & ( ) * , . / :
> ; ? @ [ \ ] ^ _ ` { | } ~ + < = > A B C D E F G H I J
> K L M N O P Q R S T U V W X Y Z
> ----- end quote
>
> Clearly, ="A">"Z" should and does return FALSE. *So the
> table is in ascending order.
> So I still find it odd that ="2">">" returns TRUE, based
> on the above table.


Well, the answer was "obvious": the documented sort order is
incorrect.

This is apparent if we put the following into consecutive cells: 0A,
9A, !, >, A, Z. Then sort ascending.

The sorted result is: !, >, 0A, 9A, A, Z.

Obviously, the __characters__ "0" through "9" fit between ">" and "A"
in the sort order.

I suspect that whoever wrote the help page was thinking of the
__numbers__ 0 through 9. But that is covered by another section in
the "sort order" help page, to wit:

----- begin quote
In an ascending sort, Microsoft Excel uses the following order.
[....]
Numbers Numbers are sorted from the smallest negative number to the
largest positive number.

Alphanumeric sort When you sort alphanumeric text, Excel sorts left
to right, character by character.
----- end quote
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Overloading binary + operator Sapo19875 Microsoft C# .NET 8 15th Apr 2008 04:19 PM
Help me!!!!! ..\Vc7\atlmfc\include\afxtempl.h(149) : error C2678: binary '==' : no operator found which takes a left-hand operand of type 'const CVideoAdapter' (or there is no acceptable conversion) IPD Microsoft VC .NET 3 10th Nov 2006 12:30 PM
Overloading "-" operator: binary and unary Leszek Taratuta Microsoft C# .NET 0 29th Mar 2005 11:01 PM
operator ~ claimed to be binary by compiler! Peter Bromley Microsoft VC .NET 1 5th Jul 2004 02:59 PM
Binary "and" operator in enum loop Peter Hemmingsen Microsoft VC .NET 3 7th Jan 2004 11:35 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:45 AM.