Python - how to count it...
HI, I'm new here so thanks for all good comments and help. I'm just after Python Tutorial, I have some ideas, but I have no practice in programming tricks yet ;) I'm thinking about function in Python which will help users to count some stuff. Here is the problem: First of all we have amount of money (Amount_A) - Defined as input We want to buy two types (or more) of things in same amount (AmountArticle_B), (AmountArticle_C) - This is what we search. Both of those things are in different price(Price_B),(Price_C) - also defined as input. Amount_A = AmountArticle_B * Price_B + AmountArticle_C * Price_C if AmountArticle_B == AmountArticle_C and AAB*PB+AAC+PC == AA Sometimes it can't be done so function should check neighbours so the number differs, on one, or two individuals etc. but we'd like them to be as close to each other as possible. I'm not awaiting final solution of pure code - just some hints what should I check and try to find it and write it by myself. Thanks for help!