Hello,
I am using perl and not bioperl because my professor has not shown us how yet. I have to extract a FASTA sequence attached to a user accession number input. E.g, If the user enters YP_02030404.1, the script should get the sequence attached to it. like this:
>gi|170079675|ref|YP_001728995.1| [Escherichia coli str. K-12 substr. DH10B]
MRVSWLESKCDTPFANNLSFISSGSSSSSSFTLASTACRNSCLCSSSIFFQVLRRNCSSNCCSISNVDIS
LSAFSFNRFETSSKMARYNLPCPRSLLAILSPPKCCNSPAISCQLRRCCSGCPSIDLNSSLRISTLERRV
LPFSLWVSNRAKFANCSSLQC
And where is this sequence to be "extracted" from? A local database? A remote database? I suggest you use your initiative and started reading the Bioperl HOW-TOs: http://www.bioperl.org/wiki/HOWTOs. What you want to do is very easy.
Can you only do what your prof. has shown you, or are you an independent mind?