Generally speaking- it is dangerous territory for someone over 18 to have sex with someone under 18.
In Alaska, the nature of the relationship between the two be known to say if it is legal or not. If the minor is emancipated, that does not effect the statutes regarding unlawful sexual intercourse.
The person that is in the military is walking on thin ice if he gets involved with a minor. The laws may effect him differently whether he is on base or off base.
Typically- it is best to avoid the whole mess. Nothing good will come from it anyway.