Another section provided for the election of district attorneys, whose duty it was made to 'attend to legal business before the courts in their respective districts where the Territory is a party, prosecute individuals accused of crimes in cases arising under the laws of the Territory, and do such other duties as pertain to their office.'