
229 S.E.2d 921 (1976)
291 N.C. 275
STATE of North Carolina.
v.
John Dewey SLADE and Douglas McArthur Slade.
No. 59.
Supreme Court of North Carolina.
December 7, 1976.
*923 Atty. Gen. Rufus L. Edmisten and Sp. Deputy Atty. Gen. John M. Silverstein, Raleigh, for the State.
Michael S. Scofield, Public Defender, James Fitzgerald and Keith M. Stroud, Asst. Public Defenders, Charlotte, for defendant-appellant.
MOORE, Justice.
Defendants were arraigned before Judge Grist on 7 January 1976 and entered pleas of not guilty. At the time of arraignment, defendants' attorney announced that there were no pretrial motions. The cases were called for trial before Falls, J., on 2 February 1976, and the trial judge, in his discretion, ordered these cases consolidated for the purpose of trial.
On the second day of trial, defendants' attorney moved that prior plea bargaining negotiations be made a part of the record. This motion was denied and defendants contend that this denied them the right to an effective appeal. We are aware that "plea bargaining" has emerged as a major aspect in the administration of criminal justice. As stated by Mr. Chief Justice Burger in Santobello v. New York, 404 U.S. 257, 260-61, 92 S.Ct. 495, 498, 30 L.Ed.2d 427, 432 (1971):
"The disposition of criminal charges by agreement between the prosecutor and the accused, sometimes loosely called `plea bargaining,' is an essential component of the administration of justice. Properly administered, it is to be encouraged. If every criminal charge were subjected to a full-scale trial, the States and the Federal Government would need to multiply by many times the number of judges and court facilities.
"Disposition of charges after plea discussions is not only an essential part of the process but a highly desirable part for many reasons. . . ."
In the past, "plea bargaining" was carried on informally between the prosecution and the defendant or defendant's attorney subject to the approval of the presiding judge as to the proper sentence to be imposed. In 1973, the procedure for "plea *924 bargaining" was formalized by the enactment of G.S. 15A-1021 through G.S. 15A-1026. G.S. 15A-1026 provides:
"A verbatim record of the proceedings at which the defendant enters a plea of guilty or no contest and of any preliminary consideration of a plea arrangement by the judge pursuant to G.S. 15A-1021(c) must be made and transcribed." (Emphasis added.)
G.S. 15A-1021(c) allows the parties to a plea arrangement to advise the trial judge of the terms of the proposed agreement, provided an agreement has been reached. These provisions are consistent with Santobello v. New York, supra, and permit a record to be made of the judge's consideration of the agreement. However, the statutes permitting a record to be made are conditioned upon an agreement being reached and a plea of guilty being entered.
In present case, there is no evidence or intimation by defendants that any agreement was made or bargain struck. This is borne out by defendants' plea of not guilty. The safeguards associated with "plea bargaining" and contained in the statutes are designed to insure that defendant is fully aware of the ramifications of his plea of guilty. Additionally, the prosecution is bound by the terms and conditions utilized to obtain the guilty plea. Santobello v. New York, supra. In present case, the fact that no agreement was reached removes the necessity for these particular safeguards.
Defendants do not contend that the negotiations concerning "plea bargaining" should have been introduced in evidence before the jury. Neither do they contend that such evidence would have been competent before the jury. See State v. Harrill, 289 N.C. 186, 221 S.E.2d 325 (1976); G.S. 15A-1025. In the absence of an agreement reached, we fail to see how defendants' right to appeal was abridged or how defendants were prejudiced by the denial of the motion to include the negotiations in the record. This assignment is overruled.
Defendant John Slade assigns as error the following portion of the charge in which the court was instructing the jury as to the aider and abettor:
"Now with respect to the aider and abetter, John, if you find from the evidence and beyond a reasonable doubt that on or about the 7th of October, 1975, the principal Parks and Douglas Slade committed the armed robbery, that is, Parks and Douglas Slade entered the store with a firearm and robbed the assistant manager of his cash in the cash drawer and money order box and other property and that the defendant John Slade was outside in his automobile waiting to carry the two that went in the store away as a get-away man and that in so doing he knowingly instigated or encouraged or advised or aided the principal Parks and Douglas Slade to commit the crime of armed robbery, even though he was not physically present in the store, that John Slade shared the criminal purpose of the principals Parks and Douglas Slade and to the knowledge of both of them and in so doing John Slade aided and abetted the principals or was in a position to aid and abet the principals at the time the crime was committed, it would be your duty to return a verdict of guilty."
Defendant John Slade contends that in this instruction the trial court erroneously defined the offense of armed robbery and that this instruction contradicted other portions of the charge. He relies upon State v. Harris, 289 N.C. 275, 221 S.E.2d 343 (1976), to support his position. In Harris, the trial court in a second degree murder case erroneously charged the jury that the defendant had the burden of satisfying the jury that the victim's death was the result of an accident. There, it was held that the incorrect charge was not cured by the correct portions of the charge, "`particularly . . when the incorrect portion of the charge is the application of the law to the facts.'" 289 N.C. at 280, 221 S.E.2d at 347. That case is distinguishable from the present case.
A case more clearly in point is State v. Bailey, 280 N.C. 264, 185 S.E.2d 683 *925 (1972). In Bailey, this Court considered a charge in an armed robbery case wherein the jury was instructed that "it is incumbent upon you to find as one of the necessary elements of the offense charged, that is robbery with a firearm, that the defendant had a firearm in his possession at the time that he obtained the property." As in instant case, the defendant in Bailey contended that these instructions would enable the defendant to be convicted of armed robbery without a finding by the jury that the life of the victim had been endangered or threatened by the use of a firearm. In Bailey, we held that there was no merit to this assignment because elsewhere in the charge the court had properly instructed the jury that defendant had obtained the property by "endangering or threatening the life of Loretta Williams with a firearm."
In present case, immediately prior to that portion of the charge to which defendants have taken exception, the trial judge instructed the jury:
"So I charge you, members of the Jury, if you find from the evidence in this case and beyond a reasonable doubt that. . . the defendants . . . had a firearm and took and carried away money and food stamps and other property from the person or presence of the assistant manager of the Little General Store without his voluntary consent by violence or putting him in fear whereby his life was threatened or endangered with the use or threatened use of a pistol, to wit: a .22 caliber pistol. . . ."
Furthermore, prior to having given this instruction, the court had fully instructed the jury as to the elements of the offense of armed robbery, including, "that the defendants had a firearm in their possession at the time they obtained the property; and seven, that the defendants obtained the property by endangering or threatening the life of the assistant manager with the firearm." Thus, there was no contradiction in the charge and the jury could not have been misled as to the elements required to constitute armed robbery.
We have said many times that a charge must be construed contextually, and an isolated portion of it will not be held prejudicial when the charge as a whole is correct. State v. Bailey, supra; State v. McWilliams, 277 N.C. 680, 178 S.E.2d 476 (1971). Construed in its entirety, the charge to the jury regarding John Slade was both fair and proper. This assignment is overruled.
At the beginning of trial, Judge Falls granted the oral motion of the State to consolidate the trials of defendants John Slade and Douglas Slade. In opposition to this motion, defendants made a motion for severance which was denied. Defendants, on appeal, contest the ruling of the trial judge in ordering that the cases be consolidated. They further contend that G.S. 15A-926(b)(1) requires that the district attorney make a written motion to join defendants for trial and that the failure of the district attorney to make such a written motion entitles them to a new trial. The two statutes relevant to the disposition of this issue are G.S. 15A-926(b)(2) and G.S. 15A-927(c)(2).
G.S. 15A-926(b)(2), in pertinent part, provides:
"(2) Upon written motion of the solicitor, charges against two or more defendants may be joined for trial: a. When each of the defendants is charged with accountability for each offense. . . ."
G.S. 15A-927(c)(2), in pertinent part, provides:
"(2) The court, on motion of the solicitor, or on motion of the defendant . . . must deny a joinder for trial or grant a severance of defendants whenever:
a. If before trial, it is found necessary to protect a defendant's right to a speedy trial, or it is found necessary to promote a fair determination of the guilt or innocence of one or more defendants. . . ."
Under these statutes, two or more defendants may be joined for trial when *926 they are accountable for the same crime. However, joinder of defendants may not be permitted where such joinder would not promote a fair determination of the guilt or innocence of one or more of the defendants. This was essentially the law prior to the passage of G.S. 15A-927(c)(2). For example, in State v. Jones, 280 N.C. 322, 185 S.E.2d 858 (1972), six defendants were charged in separate bills of indictment with the commission of the same offense. The trial court consolidated the cases for trial and defendants contended that this was error. This Court, speaking through Chief Justice Bobbitt, stated:
"`[W]hether defendants . . . [should] be tried jointly or separately [is] in the sound discretion of the trial court, and, in the absence of a showing that a joint trial [has] deprived the movant of a fair trial, the exercise of the court's discretion will not be disturbed upon appeal.. . .'" 280 N.C. at 332-33, 185 S.E.2d at 865.
See also State v. Alford, 289 N.C. 372, 222 S.E.2d 222 (1976); State v. Brower, 289 N.C. 644, 224 S.E.2d 551 (1976).
In instant case, the joinder was proper. First, each defendant was accountable for the same offensethe armed robbery of the Li'l General. Secondly, we fail to see how defendants were denied a fair determination of their guilt or innocence because of the joinder.
We cannot agree with defendants' contention that G.S. 15A-926(b)(2) requires that a motion for joinder of defendants for trial be in writing.
G.S. 15A-951(a), in pertinent part, provides:
"A motion must:
(1) Unless made during a hearing or trial, be in writing. . . ."
The district attorney's motion, made at the beginning of trial, comes within the purview of G.S. 15A-951(a) and was not required to be in writing. The language in G.S. 15A-926(b), which states, "Upon written motion of the [district attorney] . ." applies only in those instances in which joinder of defendants is requested prior to trial. Thus, we overrule these assignments.
Defendants contend that the trial judge committed error by expressing an opinion in violation of G.S. 1-180 when he instructed the jury and referred to John Slade as an "aider and abettor" and Douglas Slade as a "principal." During the charge, the trial judge stated:
"Now with respect to the aider and abetter, John, if you find from the evidence and beyond a reasonable doubt that on or about the 7th of October, 1975, the principal Parks and Douglas Slade committed the armed robbery . . . and that the defendant John Slade was outside in his automobile waiting to carry the two that went in the store away as a get-away man and that in so doing he knowingly instigated or encouraged or advised or aided the principal Parks and Douglas Slade to commit the crime of armed robbery. . . ."
Later in the charge, the trial judge again referred to Douglas Slade as a "principal."
We find no merit in defendants' contention. This Court has repeatedly held that a charge must be construed as a whole, and isolated portions of a charge will not be held to be prejudicial where the charge as a whole is correct and free from objection. 4 Strong, N.C. Index 3d, Criminal Law § 168 (1976), and the plethora of cases cited thereunder. As was stated in State v. Gatling, 275 N.C. 625, 633, 170 S.E.2d 593, 598 (1969), "It is not sufficient to show that a critical examination of the judge's words, detached from the context and the incidents of the trial, are capable of an interpretation from which an expression of opinion may be inferred." See also State v. Wetmore, 287 N.C. 344, 215 S.E.2d 51 (1975); State v. Allen, 283 N.C. 354, 196 S.E.2d 256 (1973); State v. McWilliams, 277 N.C. 680, 178 S.E.2d 476 (1971).
Reading the charge as a whole, it is clear that the trial judge was differentiating between the two defendants, one of whom was a principal, the other an aider and abettor. A trial judge is required to "explain the law arising on the evidence given *927 in the case." G.S. 1-180. The trial judge properly did so in this case. Accordingly, we find no merit in this assignment.
Defendant finally contends that the trial court erred in sentencing both defendants to life imprisonment. The basis of this contention is that the trial judge should have sentenced John Slade to a lesser sentence than that imposed upon Douglas Slade because John Slade was an aider and abettor.
A principal in the first degree is the person who actually perpetrates the deed, either by his own hand or through an innocent agent. Any other person who is actually or constructively present at the place of the crime, either aiding, abetting, assisting, or advising in the commission of the crime, or is present for that purpose, is a principal in the second degree. The distinction between principals in the first and second degrees is a distinction without a difference; both are principals and equally guilty. State v. Benton, 276 N.C. 641, 174 S.E.2d 793 (1970).
G.S. 14-87(a) provides that a defendant who is convicted of robbery with a firearm or other dangerous weapon "shall be punished by imprisonment for not less than five years nor more than life imprisonment in the State's prison." A sentence which does not exceed the maximum length as stated in the statute will not be considered cruel and unusual punishment. State v. Weston, 273 N.C. 275, 159 S.E.2d 883 (1968); State v. LePard, 270 N.C. 157, 153 S.E.2d 875 (1967). Further, as long as a sentence is within the statutory limits, the punishment imposed by a trial judge is in his discretion. State v. Garris, 265 N.C. 711, 144 S.E.2d 901 (1965).
In State v. Benton, supra, the defendant was convicted as an accessory before the fact to murder and sentenced to life imprisonment. Life imprisonment was authorized by statute as a sentence for the offense. On appeal, defendant contended that her punishment was excessive, since the actual murderer was sentenced to 20-30 years upon a plea of guilty. Since life imprisonment was authorized by the statute, this Court affirmed the sentence of defendant.
In the case at bar, the sentence imposed upon each defendant was within the statutory limits prescribed by G.S. 14-87. Each defendant was given an opportunity to present any evidence which he deemed desirable to be considered by the judge. In fact, defendant Douglas Slade did so. See State v. Perry, 265 N.C. 517, 144 S.E.2d 591 (1965). Further, the evidence showed that defendants actively participated in a robbery with a firearm in which a person, albeit a codefendant, was killed. Thus, we find that the trial judge did not abuse his discretion in sentencing defendants to life imprisonment.
An examination of the entire record discloses no error in law sufficient to constitute a basis for awarding a new trial.
No error.
