How to kill the ender dragon with a command in minecraft PE
Use /kill @e[type=EnderDragon,r=100] while you are in the same dimension as the Ender Dragon you want to kill. This command doesn’t require any command blocks, so you can just type it in the chat.