Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialOmar Suriel
5,403 Pointsi don't even understand what's the problem i need to solve? like what is he even asking us to do?
what are we supposed to do? just type out an array and then print it to the page? I dont understand what the problem we need to solve is.. i watched the video 4 times and i still dont understand what he's asking me to do
Sergio Garza
6,892 PointsI believe you are not solving any "problem" yet. This is just a test so you can see yourself if you know the correct syntax when creating an array that contains objects. There are other challenges that build up from what you create here.
3 Answers
Anas AlHariri
8,776 PointsHi my Friend Omanr,
He thought us about object and arrays, and now he wants us to make a program that has a code that has students' records that we can deal with later. While this is only the first part of the challenge I can tell that nothing clear about it.
Programming not always about solving problems. Sometimes it's about creating a solutions to make life easier. Just like instead of searching drawers in a school for a student record to check those information we are about to make. You can grab it just with this solution that provides you an easy way to deal with Data such as the student records.
Can you imagine that you need to check the percentage of passing to failing students in a school. How long would it take to check each record and make the required mathematical operations to get this done. While having a program that can store Data as an object makes it clearly way easier.
So, There is no problem to solve here, but instead we are making a program that makes life easier with dealing with Data through storing them in an object that can be sent later to a server to store them and retreat them when ever you need to check or edit them or even do mathematical operations on them.
So, for now and for the first step of this challenge we have to prepare the students' records data in a shape of using Array of Object. Each object contains a student record. So later we can continue the challenge by testing our ability to make a program that stores the data and display it for future purposes. Such as dealing with data from a server that we receive in JSON format which is at the end is an array of objects or object of objects.
In the future lessons we will do that. But now we need to make sure that we know how to do the basics first. And that's what this challenge is about.
Wish you goodluck, Gabriel Alhariri
Huseyin Erkmen
11,268 PointsThis challenge has two steps. On first step you just need to create an array with at least 5 objects. That is it. Problem is on the second step.
don graham
13,789 PointsHi Omar,
It's a lot easier than you might think. As the instructor says, you must create a data type to hold your objects. Let's take it one step at a time.
step 1: create an array to hold the students
var students = [];
step 2: fill the array with five student objects
var students = [
{},
{},
{},
{},
{},
];
step 3: give each object the following properties:
- 'name': ...
- 'track': ...
- 'achievements': ...
- 'points': ...
var students = [
/* example:
{
name: 'user name',
track: 'track name',
achievements: 23,
points: 1000
}
*/
{
key: 'value',
key: 'value',
key: 'value',
key: 'value'
},
{
key: 'value',
key: 'value',
key: 'value',
key: 'value'
}
...
];
Hope this clears things up a bit.
Omar Suriel
5,403 Pointsi' sorry but I still don't understand whats the point of this or whats the problem that im supposed to solve.... whenever i program something theres a problem and i use programing to solve it here i just dont understand what the problem is. i am confident i can solve whatever problem there is but i just dont understand what i need to solve for. i jsut dont understand what he's asking me to do.
Omar Suriel
5,403 PointsOmar Suriel
5,403 Points"creates a script that creates a bunch of student records then print those records to a web page" firstable how are you create a script thats going to "create" the student records, the students records i have to type them, so is all i have to do just print it? i have a hard time understanding the point of this