what is the diffrence between for and foreach?
Answer Posted / krunal gohel
for loop is to do something over and over again until the
task has been completed.
foreach works only on arrays. even it will run the loop
until end of the array.
| Is This Answer Correct ? | 15 Yes | 6 No |
Post New Answer View All Answers
Tell me what is the definition of a session?
How do you destroy a session?
What Is a Persistent Cookie?
Tell me what are magic methods?
Explain me the difference between include and require?
How to pass an argument to a function?
Where do we use get and post?
Is php dying 2018?
How a constant is defined in a php script?
What is difference between session and cookie in PHP?
What is the difference between associative array and indexed array?
What is htaccess? Why do we use this and where?
Can we override magic methods in php?
How can you get web browser’s details using PHP?
What is php good for?