Use -ExpandProperty in your choice.
Get-FileHash file.ext -Algorithm MD5 | select -ExpandProperty Hash >file.md5
Or like that
(Get-FileHash file.ext -Algorithm MD5).Hash > file.md5
In a loop, it might look something like this (the hash for "file.ext" will fall into a file called "file.ext.md5".
Get-ChildItem * -Include '*.ext' | foreach { (Get-FileHash $_ -Algorithm MD5).Hash > "$($_.Name).md5" }
source share