2

what do we call this sign => in PHP array? example: like this is (<= less than equal to) this is (>= greater than equal to).

What is the right name for => in PHP?

James Z
  • 12,209
  • 10
  • 24
  • 44
  • Rajendra - It would probably help if you showed an example of what you're talking about. But again, I very much doubt it has a specific name. Also, do you really mean to ask what it's **called**? Or did you want to know what it **means**? – T.J. Crowder Oct 05 '21 at 06:52
  • 1
    T.J. thanks for your ans i know what it sign means and what it does but, i curious to know what it called generally. – Rajendra Singh Oct 05 '21 at 06:57

2 Answers2

4

Colloquially I believe it's often called a fat comma or double arrow, but I still prefer to call it a fat arrow, even though the official token is called T_DOUBLE_ARROW

https://en.wikipedia.org/wiki/Fat_comma#PHP

T.J. Crowder
  • 1,031,962
  • 187
  • 1,923
  • 1,875
Joel Peltonen
  • 13,025
  • 6
  • 64
  • 100
  • @T.J.Crowder Noted - but I think the deceze answered the technically correct term and I was trying to cover what that might be called when speaking to a fried/collague/recruiter - not really what is techically correct :) – Joel Peltonen Oct 05 '21 at 07:01
  • The PHP section of that page supports your answer well. – T.J. Crowder Oct 05 '21 at 07:02
3

Internally it appears to be called a T_DOUBLE_ARROW: http://www.php.net/manual/en/tokens.php

deceze
  • 510,633
  • 85
  • 743
  • 889
  • Which, if you ask me, sounds slightly confusing… I'd call `>>` a "double arrow", but that's not the first thing that comes to mind for `=>`… – deceze Oct 05 '21 at 06:58
  • :-) I'm guessing the "double" is for the `=` (vs. `-`), though "fat" and "thin" are the terms I usually hear... – T.J. Crowder Oct 05 '21 at 07:03