How do I extract specific pages from a PDF file using Ghostscript from the command line?

gswin64c -sDEVICE=pdfwrite -dNOPAUSE -dBATCH -dSAFER -dFirstPage=70 -dLastPage=71 -sOutputFile=output.pdf input.pdf

How do I convert PDF to PNG images from the command line using Ghostscript?