I have a very basic question. 

I have created simple ArrayList and I am removing the item while iterating using for-each loop. It gives me java.util.ConcurrentModificationException because I can't remove an item while iterating but when I un-comment the if condition it works fine. 

Please can anybody explain me how for-each works in this way.      

    ArrayList&lt;String&gt; list1 = new ArrayList&lt;String&gt;();
    list1.add("Hello");
    list1.add("World");
    list1.add("Good Evening");

    for (String s : list1) {
        //if (s.equals("World")) {
            list1.remove(1);
        //}
    }


If I change it to list1.remove(2); or list1.remove(0); then also its working fine. 

Note: This is sample code and I know it will work fine using Iterator. My sole purpose of this question is to know how method remove() works perfectly if condition is un-commented no matter what index you are removing from the list.


Question: What is the relationship between Gabriel and Noah in LDS/Mormon teaching?
Answer: According to LDS doctrine, it's not so much that men or angels "become" one another, as that they are the same order of creation.

From the same reference, under Angels, we read:


  There are two kinds of beings in heaven who are called angels: those
  who are spirits and those who have bodies of flesh and bone. Angels
  who are spirits have not yet obtained a body of flesh and bone, or
  they are spirits who have once had a mortal body and are awaiting
  resurrection. Angels who have bodies of flesh and bone have either
  been resurrected from the dead or translated.
  
  There are many references in scripture to the work of angels.
  Sometimes angels speak with a voice of thunder as they deliver God’s
  messages (Mosiah 27:11–16). Righteous mortal men may also be called
  angels (JST, Gen. 19:15). Some angels serve around the throne of God
  in heaven (Alma 36:22).


The angel Gabriel is primarily known to Christians through his role in informing Mary and Zacharias about the important roles that their unborn children would play.  Genesis 9:29 informs us that Noah died, and as these events (as well as certain events in the book of Daniel that mention Gabriel) took place before the Resurrection of Jesus Christ, it's safe to say that he was, at this point, one of the spirits who "once had a mortal body and are awaiting resurrection."

The distinguishing characteristic seems to be not so much one of nature as of vocation; an angel is a servant of God--generally a non-mortal one (the one exception mentioned in the reference article refers to the messengers sent to Lot in Sodom, which is a somewhat ambiguous case)--with some special mission or duty to perform.