Adding implementation of program check