This should do:
awk '{print $NF}' file.txt > file2.txt
or shortest solution of the day:
awk '{$0=$NF}1' file.txt > file2.txt
cat file2.txt
fghfg
sdfsd
thrt
wefs
dfd
htyj
dfd
gsedf
sdfsdf
sdfghj
fgdfhtyu
dfdsfsd
sdgdfg
sdfzcxzc
fgjty
Just print the last column.