Seems like driver malfunction. If you are using simple normal keyboard, kindly open device manager and uninstall driver for those malfunctioning devices. After that click "Scan for hardware changes". This will basically reset your driver for device. If you use a custom keyboard like razer or logitech, you may have to download their own provided driver from their support site or from included CD.