Reformating the code and adding get_competitor method