solved the problem that variable 'pc' was unused