my @array=('data1','data2');
my @array1=('data1','data2');
my ($i,$k);
$i=7;
$k=7;
while($i){
$array [++$#array] = 'ree';
$i--;
print "@array";
}
while($k){
push(@array1,'ree');
$k--;
print "@array1";
}
Are these two while loop are doing the same functionality ?
What may be the difference?
Answer Posted / neo
Both are same
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
What are the various advantages and disadvantages of perl?
Write a cgi program to show the header part?
What does next statement do in perl?
Differences between die and exit.
Explain grooving and shortening of arrays and splicing of arrays?
How to close a directory in perl?
How does polymorphism work in perl?
Explain perl. What are the advantages of programming in perl?
How to check the status of airplane mode (enable/disable) in perl for Android mobile?
“The methods defined in the parent class will always override the methods defined in the base class”. What does this statement means?
Which statement has an initialization, condition check and increment expressions in its body? Write a syntax to use that statement.
How to convert strings into an array in perl?
What package you use to create a windows services?
Explain 'grep' function.
What is the use of –w?