funtions and files