Difference between microcontroller and microprocessor in electrical
Answers
any external circuits to do its task so microcontrollers are heavily used in embedded systems and major microcontroller manufacturing companies are making them to be used in embedded market. A microcontroller can be called the heart of embedded system. Some examples of popular microcontrollers are 8051, AVR, PIC series of microcontrollers,.

Above is architecture of 8051 microcontroller. And you can see all the required components for a small project is present in a single chip.
Microprocessor
Microprocessor has only a CPU inside them in one or few Integrated Circuits. Like microcontrollers it does not have RAM, ROM and other peripherals. They are dependent on external circuits of peripherals to work. But microprocessors are not made for specific task but they are required where tasks are complex and tricky like development of software’s, games and other applications that require high memory and where input and output are not defined. It may be called heart of a computer system. Some examples of microprocessor are Pentium, I3, and I5 etc.

From this image of architecture of microprocessor it can be easily seen that it have registers and ALU as processing unit and it does not have RAM, ROM in it.
So, what is the difference between microprocessor and microcontroller?
As now you are basically aware of what is a microcontroller and microprocessor, it would be easy to identify the major differences between a microcontroller and microprocessor.