Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7956747
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T04:05:04+00:00 2026-06-04T04:05:04+00:00

It was explained to me by a more senior PHP programmer that using PHP

  • 0

It was explained to me by a more senior PHP programmer that using PHP arrays is inefficient as it results in extra data copying. He then explained that you get less memory consumption and more performance by creating classes to hold your data, even arrays. PHP would then not feel compelled to copy/deep copy the data in a class as it would an array of arrays.

He also explained the object I would be looking for would be easier to find in a proper structured tree of objects than an array of arrays. This I can understand.

Here comes the questions, I know they’re a little vague.

  • Is there ever a proper situation to use an array of arrays over an object to store data?

  • Will it always be more memory and performance efficient to store data in objects?

Thanks a lot in advance guys, I could write and profile a bunch of PHP apps to figure it out but I’m sure a lot of you already know the answer.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T04:05:05+00:00Added an answer on June 4, 2026 at 4:05 am

    This guy did a test and it seems there is not much difference : http://www.rooftopsolutions.nl/blog/148

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How have you explained nested arrays to a programmer. I'm thinking someone that has
The process is explained here: http://msdn.microsoft.com/en-US/library/d1ae6tz5%28v=VS.80%29.aspx What I don't get from that article is
This is best explained using code. I have a generic class that has a
i found http://visualjquery.com/ more useful when i was learning jQuery with each function explained
As explained here , Math.Ceiling returns: The smallest integral value that is greater than
Found this question that explained a way to communicate between layers. However there is
An earlier question explained that on x86 the size of objects being watched is
Im trying to develop a friends module to get more aquainted with django. Now
How can I get a regular expression that matches any string that has two
i have read articles that say: using the prototype will be fastest since functions

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.