View Full Version : (Java) Protein Folding Problem (simple calculation fail)
Max_Mackie
January 29th, 2011, 09:30 AM
solved :)
Thank you.
Max_Mackie
January 29th, 2011, 08:43 PM
bump
unknownPoster
January 29th, 2011, 09:14 PM
bump
You're only supposed to bump once every 24 hours. Patience is a key thing in this forum. That being said, just from the code you have provided. The "grid" elements are never initialized. Your if statements will always fail b/c grid[i][j] will never be 'h' or 'p' or maybe they are initialized to whatever namearray is. You need to provide more code.
Max_Mackie
January 29th, 2011, 11:58 PM
Pardon me for the early bump :)
What do you mean by initializing each element? I initialize the matrix at the beginning (char[][] grid = new char[51][51];). I'm saying if the string contains an 'h', put it in this grid square.
Thanks for your reply
TheCivilian
January 30th, 2011, 12:52 AM
Hi Max_Mackie,
just by looking at a section of your code it is difficult to analyze the entirety of the problem. There may be a problem within another part of your code and it would be wise to provide more of your code. The method that you have provided from the website seems to have other parts that may be affecting your code. Before attacking the question, it would be wise on my part to not jump to a conclusion before seeing the other class files.
Best regards,
TheCivilian
Max_Mackie
January 30th, 2011, 01:23 AM
Hey thanks for answering :)
I've uploaded a .zip file with my classes.
Thanks for offering to help.
Powered by vBulletin® Version 4.2.2 Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.