<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def device_discovered (self, address, device_class, rssi, name):
 """ Called when a bluetooth device is discovered. address is the bluetooth address of the device device_class is the Class of Device, as specified in [1] passed in as a 3-byte string name is the user-friendly name of the device if lookup_names was set when the inquiry was started. otherwise None This method exists to be overriden. [1] https://www.bluetooth.org/foundry/assignnumb/document/baseband """

        if name:
            print(("found: %s - %s (class 0x%X, rssi %s)" % \
                    (address, name, device_class, rssi)))
        else:
            print(("found: %s (class 0x%X)" % (address, device_class)))
            print(("found: %s (class 0x%X, rssi %s)" % \
                    (address, device_class, rssi)))