TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Ganesh Parate
NA
10
1.7k
Below is the code . i want do it using only one for loop.
Dec 8 2017 2:23 AM
Below is the code . i want do it using only one for loop in PHP. Please help me how can i achieve it... Thanks
//Rewrite the code below so it would contain only one loop and only one iterational variable would be used.
$result = Array();
for ($x = 0; $x < 6; $x++){
for ($y = 0; $y < 6; $y++){
for ($z = 0; $z < 6; $z++){
$result[$x][$y][$z] = $x * $y * $z;
}
}
}
Reply
Answers (
2
)
Linq Dynamic query for getting dynamic list based on Id
Any Suggestions or comments on the following code please