We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
///where the limit int is lesser than or equal to the original array of Inventory object's threshold attribute.
public static Inventory[] replenish(Inventory[] inventories, int limit){ Inventory[] refined = new Inventory[0]; for (int i = 0; i < inventories.length; i++){ if (inventories[i].getThreshold() <= limit){ ///// change to (inventory[i].getThreshold() >= limit) refined=Arrays.copyOf(refined, refined.length+1); refined[refined.length-1] = inventories[i]; } } return refined; }
The text was updated successfully, but these errors were encountered:
Hey @kumarqwe, Glad you found this issue. Would you be willing to raise a PR for this?
Sorry, something went wrong.
No branches or pull requests
///where the limit int is lesser than or equal to the original array of Inventory object's threshold attribute.
public static Inventory[] replenish(Inventory[] inventories, int limit){
Inventory[] refined = new Inventory[0];
for (int i = 0; i < inventories.length; i++){
if (inventories[i].getThreshold() <= limit){ ///// change to (inventory[i].getThreshold() >= limit)
refined=Arrays.copyOf(refined, refined.length+1);
refined[refined.length-1] = inventories[i];
}
}
return refined;
}
The text was updated successfully, but these errors were encountered: