![subject](/tpl/images/cats/informatica.png)
Computers and Technology, 06.05.2020 02:28 ineedhelp2285
You are provided with the following program poem. cpp. All is good, and the memory is allocated dynamically, but it crashes your computer, because it runs out of memory really quickly:
#include
using namespace std;
string * createAPoemDynamically() {
string *p = new string;
*p = "Roses are red, violets are blue";
return p;
}
int main() {
while(true) {
string *p;
p = createAPoemDynamically();
// assume that the poem p is not needed at this point
}
}
Fix this program poem. cpp. It should still keep creating poems, but all dynamically allocated memory should get deleted when it is not needed.
![ansver](/tpl/images/cats/User.png)
Answers: 2
Another question on Computers and Technology
![question](/tpl/images/cats/informatica.png)
Computers and Technology, 22.06.2019 18:00
Martha is a healer, a healthcare provider, and an experienced nurse. she wants to share her daily experiences, as well as her 12 years of work knowledge, with people who may be interested in health and healing. which mode of internet communication can martha use?
Answers: 3
![question](/tpl/images/cats/informatica.png)
Computers and Technology, 23.06.2019 02:00
Arecipients list has been loaded into a document. which commands should be clicked in order to filter the list so that letters will not be printed for recipients who live in a certain state? mailings tab, start mail merge, select recipients, type new list, then insert only contacts from the desired states mailings tab, rules, select recipients, use existing list, then choose a recipients list that includes only contacts in certain states mailings tab, select recipients, use existing list, rules, fill in, then type in certain states mailings tab, rules, skip record select “state” under field name, then type in the state name under “equal to”
Answers: 2
![question](/tpl/images/cats/informatica.png)
Computers and Technology, 23.06.2019 09:30
The place where the extended axis of the earth would touch the celestial sphere is called the celestial
Answers: 1
![question](/tpl/images/cats/informatica.png)
You know the right answer?
You are provided with the following program poem. cpp. All is good, and the memory is allocated dyna...
Questions
![question](/tpl/images/cats/en.png)
![question](/tpl/images/cats/ekonomika.png)
![question](/tpl/images/cats/en.png)
![question](/tpl/images/cats/mat.png)
Mathematics, 07.04.2020 19:56
![question](/tpl/images/cats/mat.png)
Mathematics, 07.04.2020 19:56
![question](/tpl/images/cats/mat.png)
Mathematics, 07.04.2020 19:56
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/en.png)
English, 07.04.2020 19:56
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/istoriya.png)
History, 07.04.2020 19:56
![question](/tpl/images/cats/istoriya.png)
History, 07.04.2020 19:56
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/fizika.png)
![question](/tpl/images/cats/ekonomika.png)
![question](/tpl/images/cats/obshestvoznanie.png)
![question](/tpl/images/cats/mat.png)
Mathematics, 07.04.2020 19:56
![question](/tpl/images/cats/mat.png)
Mathematics, 07.04.2020 19:56
![question](/tpl/images/cats/istoriya.png)
![question](/tpl/images/cats/ekonomika.png)