/* package whatever; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

interface IMotor extends ICambio {
    public void SetMotor(String v);
}
interface ICambio {
    public void SetCambio(String v);
}
interface IRobo {
    
}
class Car implements IMotor, IRobo{

    /**
     * @return the id
     */
    public Integer getId() {
        return id;
    }

    /**
     * @param id the id to set
     */
    public void setId(Integer id) {
        this.id = id;
    }

    /**
     * @return the description
     */
    public String getDescription() {
        return description;
    }

    /**
     * @param description the description to set
     */
    public void setDescription(String description) {
        this.description = description;
    }
    private Integer id;
    private String description;

    @Override
    public void SetMotor(String v) {
        throw new UnsupportedOperationException("Not supported yet."); 
    }

    @Override
    public void SetCambio(String v) {
        throw new UnsupportedOperationException("Not supported yet."); 
    }
}

class Ideone
{
	public static void main (String[] args) throws java.lang.Exception
	{
		Car car = new Car();
        Class<?>[] interfaces = car.getClass().getInterfaces();
        ArrayList<String> items = new ArrayList<>();
        SetInterfaces(interfaces, items)
                .forEach((item) -> {
                    System.out.println(item);
                });
	}
	public static ArrayList<String> SetInterfaces(Class<?>[] interfaces, ArrayList<String> items)
    {        
        for (Class<?> intf : interfaces) {
            items.add(intf.getName());
            SetInterfaces(intf.getInterfaces(), items);
        }
        return items;
    }
}