Click here to Skip to main content
15,922,574 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Can anybody say why no data gets shown? Pin
WREY12-Jul-03 18:20
WREY12-Jul-03 18:20 
GeneralRe: Can anybody say why no data gets shown? Pin
Michael Dunn12-Jul-03 18:37
sitebuilderMichael Dunn12-Jul-03 18:37 
GeneralRe: Can anybody say why no data gets shown? Pin
Mike Dimmick13-Jul-03 1:44
Mike Dimmick13-Jul-03 1:44 
GeneralRe: Can anybody say why no data gets shown? Pin
WREY13-Jul-03 4:28
WREY13-Jul-03 4:28 
GeneralProblem by getting new object in GDI+, Help me. Pin
Behzad Ebrahimi12-Jul-03 9:08
Behzad Ebrahimi12-Jul-03 9:08 
GeneralRe: Problem by getting new object in GDI+, Help me. Pin
Neville Franks12-Jul-03 13:02
Neville Franks12-Jul-03 13:02 
GeneralRe: Problem by getting new object in GDI+, Help me. Pin
PJ Arends12-Jul-03 16:30
professionalPJ Arends12-Jul-03 16:30 
Generalpush_back, push_front Pin
DaveE9th12-Jul-03 8:00
DaveE9th12-Jul-03 8:00 
I'm having a difficult time understanding the code below (specifically how push_back and push_front work), I was hoping someone might please explain it. See addition code below if you'd like to view more. Thank you.
<br />
   for(int a = 0; a <= 10; a++)<br />
   {<br />
      mylist.push_back(a * 2);//what does this do?<br />
      if(a) mylist.push_front(a * -2);//what does this do?<br />
   }<br />

-------------------------------------------
<br />
// list.cpp<br />
#include <list>       <br />
#include <iostream>   <br />
<br />
using namespace std;<br />
<br />
void OutputList(list<int> output)<br />
{<br />
   list<int>::iterator pos;<br />
<br />
   for(pos = output.begin(); pos != output.end(); ++pos)<br />
      cout << *pos << " ";<br />
   cout << endl << endl;<br />
}<br />
<br />
int main()<br />
{<br />
   list<int> mylist;<br />
   list<int>::iterator pos;<br />
<br />
   for(int a = 0; a <= 10; a++)<br />
   {<br />
      mylist.push_back(a * 2);<br />
      if(a) mylist.push_front(a * -2);<br />
   } <br />


Big Grin | :-D

"The man who reads nothing is better educated than the man who reads nothing but newspapers."- Thomas Jefferson


GeneralRe: push_back, push_front Pin
Mike Dimmick12-Jul-03 8:17
Mike Dimmick12-Jul-03 8:17 
GeneralRe: push_back, push_front Pin
DaveE9th12-Jul-03 8:32
DaveE9th12-Jul-03 8:32 
GeneralRe: push_back, push_front Pin
Mike Dimmick12-Jul-03 8:54
Mike Dimmick12-Jul-03 8:54 
GeneralRe: push_back, push_front Pin
DaveE9th12-Jul-03 17:40
DaveE9th12-Jul-03 17:40 
GeneralOffsets and stuff Pin
Anonymous12-Jul-03 7:48
Anonymous12-Jul-03 7:48 
GeneralRe: Offsets and stuff Pin
Mike Dimmick12-Jul-03 8:27
Mike Dimmick12-Jul-03 8:27 
GeneralRe: Offsets and stuff Pin
Toni7813-Jul-03 11:08
Toni7813-Jul-03 11:08 
QuestionCan anyone help me?? Pin
Snyp12-Jul-03 6:47
Snyp12-Jul-03 6:47 
AnswerRe: Can anyone help me?? Pin
Christian Graus12-Jul-03 18:03
protectorChristian Graus12-Jul-03 18:03 
Generaltext drawing in spiral form Pin
Member 47204512-Jul-03 5:47
Member 47204512-Jul-03 5:47 
GeneralRe: text drawing in spiral form Pin
adamUK12-Jul-03 10:54
adamUK12-Jul-03 10:54 
Generalstopping and resuming an application from mfc Pin
haritadala12-Jul-03 5:39
haritadala12-Jul-03 5:39 
GeneralProblem with LoadLibrary Pin
AnTri12-Jul-03 2:52
AnTri12-Jul-03 2:52 
GeneralRe: Problem with LoadLibrary Pin
Ryan Binns12-Jul-03 3:24
Ryan Binns12-Jul-03 3:24 
GeneralRe: Problem with LoadLibrary Pin
AnTri12-Jul-03 5:14
AnTri12-Jul-03 5:14 
GeneralRe: Problem with LoadLibrary Pin
Ryan Binns12-Jul-03 18:33
Ryan Binns12-Jul-03 18:33 
GeneralNesting splitter windows Pin
Bob Stanneveld12-Jul-03 2:08
Bob Stanneveld12-Jul-03 2:08 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.