public TruthTable(String ask, String tell) {
		this.ask = ask;
		TellSplitter ts = new TellSplitter(tell);
		KB = ts.getKB();
		rules = ts.getRules();
		
		
	/*
		for loops below are used to split the KB into symbols and then remove duplicates symbols
	*/
		for(String sentence : KB)		//p1 & p2 => c
		{
			for(String splitRule : sentence.split("=>"))		//p1 & p2, c
			{
				for(String symbol : splitRule.split("&"))	//p1, p2, c
				{
					symbols.add(symbol);
				}
			}
		}
		
		//remove any duplicates symbols
		Set<String> setItems = new LinkedHashSet<String>(symbols);
		symbols.clear();
		symbols.addAll(setItems);
		
	/*
		for loops below are used to map position of symbols and rules to the truth table
	*/
		for(int i = 0; i < symbols.size(); i++)
		{
			positionTruthTable.put(symbols.get(i), i);
		}
		
		for(int i = 0; i < rules.size(); i++)
		{
			int offset = symbols.size();
			positionTruthTable.put(rules.get(i), i + offset);
        }
        
		//generate truth table depending of how many symbols are there
		//and perform calculations
		generateTruthTable(symbols.size());
	}