-
-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
loadbytes, loadTable and some minor fixes with other modified functions. #7638
base: dev-2.0
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@perminder-17 Changes look good, only please resolve the conflicts in the PR and I had a small question regarding a potential for loop that might be needed instead of explicitly unfolding it.
@davepagurek @limzykenneth
* // Display each table cell value on the canvas one below the other. | ||
* // We use a variable 'y' to increment the vertical position. | ||
* let y = 20; | ||
* text(table.getString(0, 0), 10, y); // 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is there a pedagogical or didactic reason to have these additions unfolded and not in a for loop like in the rest of the previous examples? It's correct of course, but I found it strange and different than the pattern you were following up until now.
I see that each line has the comment of the Animal type, but since its not being rendered, was wondering if it would not be best to show the list after the a for loop.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, Cristian, but these are just modified functions, I have just updated it so it should display on the canvas instead of my console. Here's the previous implementation which again didn't uses a for loop in it.
* print(table.getString(0, 0)); // 0
* print(table.getString(0, 1)); // Capra hircus
* print(table.getString(0, 2)); // Goat
* print(table.getString(1, 0)); // 1
* print(table.getString(1, 1)); // Panthera pardus
* print(table.getString(1, 2)); // Leopard
* print(table.getString(2, 0)); // 2
* print(table.getString(2, 1)); // Equus zebra
* print(table.getString(2, 2)); // Zebra
so, I didn't change it completely using a for loop.
No description provided.