How to make the following assignment, as arrayreference
assignment ?
my $arr_ref='[1,2,3,4,4,'elem']';
Answers were Sorted based on User's Feedback
Answer / kiruthikau
Refer this program.
[code]
my $ref=[1,2,3,4];
print ref $ref;
[/code]
Is This Answer Correct ? | 0 Yes | 0 No |
my $ref=[1,2,3,4];
print ref $ref;
ref will return the type of reference.
In this case ref will return as 'ARRAY'.
Is This Answer Correct ? | 0 Yes | 0 No |
What is the tk module?
What is the difference between localtime() and gmtime() functions?
How to do comment in perl?
Mention the difference between die and exit in Perl?
For a situation in programming, how can you determine that Perl is a suitable?
How can arrays be tied?
what is Polymorphism in Perl?
What are some common methods to all handles in perl?
What are the different instances used in cgi overhead?
What are the purpose of close(), getc() and read() functions?
List the files in current directory sorted by size ?
What are perl variables?