/* * Bildet eine Frucht im Rechner nach * @author Tom Eicher */ public abstract class Frucht implements Artikel { protected boolean essbar; protected int vitCproG; protected int gewichtInG; public Frucht(boolean istEssbar, int g, int vitc) { essbar = istEssbar; vitCproG=vitc; gewichtInG = g; } public int berechneVitaminC() { return vitCproG * gewichtInG; } }