Wednesday, 22 January 2014

Data types in Perl

Perl interpreter can handle 3 basic data types :


  • Scalar - it stores single values. It must have the $ prefix sign Eg: $myvar
  • Array - it is used to multiple scalar values. It must have the @ prefix sign Eg: @my_array
  • Hash - it uses associate arrays which has key-value pairs. It must have the % prefix sign Eg: %my_hash

No comments:

Post a Comment

Related Posts Plugin for WordPress, Blogger...
eXTReMe Tracker