Answer:
1.word = "George slew the dragon"
startIndex = word.find('dr')
endIndex = startIndex + 4
drWord = word[startIndex:endIndex]
2. sentence = "Broccoli is delicious."
sentence_list = sentence.split(" ")
firstWord = sentence_list[0]
Explanation:
The above snippet is written in Python 3.
1. word is initialized to a sentence.
Then we find the the occurence of 'dr' in the sentence which is assign to startIndex
We then add 4 to the startIndex and assign it to endIndex. 4 is added because we need a length of 4
We then use string slicing method to create a substring from the startIndex to endIndex which is assigned to drWord.
2. A string is assigned to sentence. Then we split the sentence using sentence.split(" "). We split based on the spacing. The inbuilt function of split returns a list. The first element in the list is assigned to firstWord. List uses zero based index counting. So. firstWord = sentence_list[0] is use to get first element.
Answer:
Form and reports are the documents which are used to create for include the information according to the particular requirements. These are the types of documents which include some extra information in the predefined information according the particular needs and requirements.
The following are the guidelines when developing forms and reports are:
- If the data or information is in the form of table then, use the query module for defining the particular relationship of table.
- Use the proper syntax and appropriate language to define the information in the forms and reports so, it become easy to the users or customers for access the information.
- During the form development, we can also provide the validation requirement and many toolbar buttons to make easy for users.
In microsoft powerpoint there are 2 or two standard colors for text in a theme. If you use a theme on your presentation, a theme is always equipped with two types of colors for the text, because it gives you more options on what color suits your text and blends with the theme perfectly.
Answer:
the branch of mathematics concerned with the analysis of strategies for dealing with competitive situations where the outcome of a participant's choice of action depends critically on the actions of other participants
Explanation:
In simple terms Game theory is the study of how and why people make decisions.
Answer:
Correct answer is:
communicate the purpose of the code that follows it.
Explanation:
Let have a look at each option
comment should give the reader the background of the programmer.
Comments are unable to do so.
Be written on every line
No, it is not need as comment are useful only to explain difficult or complex part of code.
communicate the purpose of the code that follows it.
yes, this option is true, as comments will give hints to programmer about the piece of code.
give information about how many hours it took to write the code
No, comments can answer it,