Logo F2FInterview

Perl Interview Questions

Q   |   QA

open FILEHANDLE - used to open data files and filehandle points to the file that is opened
read FILEHANDLE, SCALAR, LENGTH - used to read from filehandle of length LENGTH and the result is placed in SCALAR.
close FILEHANDLE - closes file after reading is complete.

- Scalars : store single values and are preceded by $ sign
- Arrays: store a list of scalar values and are preceded by @ sign
- Hashes: store associative arrays which use a key value as index instead of numerical indexes. Use % as prefix.

-Arithmetic operators, +, - ,* etc
-Assignment operators: += , -+, *= etc
-Increment/ decrement operators: ++, --
-String concatenation: ‘.’ operator
-comparison operators: ==, !=, >, < , >= etc
-Logical operators: &&, ||, !

@sumarray = (@arr1,@arr2);
We can also use the push function to accomplish the same.

-by setting its length to any –ve number, generally -1
-by assigning null list

In order to link this F2FInterview's page as Reference on your website or Blog, click on below text area and pres (CTRL-C) to copy the code in clipboard or right click then copy the following lines after that paste into your website or Blog.

Get Reference Link To This Page: (copy below code by (CTRL-C) and paste into your website or Blog)
HTML Rendering of above code: