Linked List Program Problem...?
816527
You have a return character leaking over in the input stream from when you make your Choice.  If you change this line\n\ncout << endl << "Your choice=> " << Choice << endl;\n\nto\n      \ncout << endl << "Your choice=> " << Choice << endl;\ncin.ignore(1);\n\nIt will remove the return character.  There's probably a better way to handle this type of problem, but my mind is fuzzy at the moment.\n\nFixing that problem, you are presented with another problem of removing names with spaces in it from your list.  To fix that use\n\ngetline( cin, Value);\n\ninstead of\n\ncin  >> Value;\n\nin your Remove function.  The latter piece of code places a null character at the first space it sees in the input stream which you don't want.  The former correctly places the entire string into Value.
694117
The first thing that I notice is that you never close the BufferedWriter.  \n\nThe second thing is that you are using append() on the BufferedWriter.  I had never heard of the append method for it, so I tried looking in the API, but it doesnt list it. I'm not sure where that came from, but you may want to try using bw.write(s);
193431
Probably because the constructor doesn't accept objects as arguments. Just a guess, though.
138457
Assuming this is in C, this is an impossible problem given the main program you provided, because you're passing in the parameters by value rather than by reference.  So any changes you make to those values inside the function will disappear once you return to the main context.\n\nIf you're allowed to change the main program to use pointers, you could do this:\n\nvoid sort2 (int *a, int *b) {\n  int tmp;\n\n  if (*a > *b) {\n   tmp = *a;\n   *a = *b;\n   *b = tmp;\n  }\n}\n\nGiven your main program, you'd call it like this:\n  sort2(&u, &v);\n\nBut it may be that this assignment was given to you specifically to demonstrate that you can't change the value of variables that you pass in by value).
1110691
Here is something I came up with quickly ( not fully complete, I will leave that to you ! ) \n\nThis quick bit of code will give you a start ( hopefully and no recursion ).\n\nPlease note that this is not complete and you will get a memory leak in swap function ( easily fixed btw ! ).\n\n#include "stdafx.h"\n#include "stdio.h"\n#include "string.h"\n\nvoid manipulate( char* pString, int index );\nchar* swap( char* pString, int pos );\n\nchar pod[255];\n\n\nint main(int argc, char* argv[])\n{\n\n  char* p = "abc";\n  memcpy( pod, p, strlen( p ) );\n  for( int i = 0; i < strlen( p ); i ++ )\n  {\n    manipulate( pod, strlen( p ) );\n  }\n  return 0;\n}\n\n\nvoid manipulate( char* pString, int index )\n{\n  int i = 1;\n  char* p;\n  p = pString;   \n  while( index > 1 ) \n  {\n    p = swap( p, i );\n    index--;\n    i++;\n    memcpy( pod, p, strlen( pString ) );\n    printf( "%s&#92;n", p );\n  }\n}\n\nchar* swap( char* pString, int pos )\n{\n  char* p = new char[ strlen(pString) + 1 ];\n  memset( p, '&#92;0', strlen( pString ) + 1);\n  memcpy( p, pString, strlen( pString ) + 1 );\n  char temp = p[pos];\n  p[pos] = pString[pos-1];\n  p[pos-1] = temp;\n  return p;\n}
765887
Assuming your above program works, which I don't think it will because your doing an aggregate operation on an array..you should assign values to indexes in the array...eg cin >> Date[0] or use a for loop or something...regardless since your putting everything in an array anyway simply do something like using a counter variable, personally i think it would be the easiest way of doing something like that.\n\nint counter = 0;\n\ncout << enter day to subtract << endl;\ncin   >> counter;\ncout << Date[1]  - Date[counter] << endl;\n\nI belive using
333931
I don't think the error is in iostream.h it's an old library\nthat exist since the invention of c++, you probably have something wrong with ur code.. try to publish the error msg it might help
211643
I can see that you're attempting to perform\na post-order walk to delete the entire tree.\n\nOne issue I see is that you do not check \nbeing on a leaf node.  You should check for\nNULL before recursing down the left and right\nbranches:\n\nif (tnPtr->left_ != NULL)\nDeleteWholeTree(tnPtr->left_);\n\nif (tnPtr->right_ != NULL)\nDeleteWholeTree(tnPtr->right_)\n\nOtherwise, you run the risk of dereferencing a NULL\nin the recursive call.
195373
Try this:\n\n#include <stdio.h>\n\nmain()\n{\nint size,array[50],n,m,border,max,buf,step;\nint i, j, temp;\n\nprintf("Input number of elements in array:");\nscanf("%d",&size);\n\nfor(n=0;n<size;n++) {\n  printf("input %d. element of array:",n+1);\n  scanf("%d",&array[n]);\n  }\n\n for (i=(size-1);i>=0; i--)\n  {\n   for(j=1;j<=i;j++)\n    {\n     if(array[j-1]>array[j])\n      {\n       temp=array[j-1];\n       array[j-1]=array[j];\n       array[j]=temp;\n      }\n     }\n   }\n\nfor(n=0;n<size;n++)\n   printf("%d. element: %d&#92;n",n+1,array[n]);\n\n}\n\n\n\nHERE IS MY OUTPUT:\n\nInput number of elements in array:8\ninput 1. element of array:6\ninput 2. element of array:2\ninput 3. element of array:3\ninput 4. element of array:5\ninput 5. element of array:1\ninput 6. element of array:4\ninput 7. element of array:5\ninput 8. element of array:7\n1. element: 1\n2. element: 2\n3. element: 3\n4. element: 4\n5. element: 5\n6. element: 5\n7. element: 6\n8. element: 7
177983
simple chk out:\n\nhttp://www.cplusplus.com/doc/tutorial/structures.html
775271
if this is a .c file, then the reason is that you have declared local variables AFTER a function call.  This is legal in c++ but not in c.\n\nswap the printf and char lines and it should work.
169151
int\nmain (void)\n{\nfor(i=0;i<10;i++){\nprintf("some thing output here %d", i)\n}\n}
487486
#define QUEUE_EMPTY 2\n\n#define TRUE_EMPTY1\n#defineFALSE_EMPTY0\n\ntypedef struct node\n{\nint data;\nstruct node *link;\n} Queue;\n\n\nintDequeue(Queue **front, Queue **rear);\nintEmptyQueue(Queue **q);\n\nint Dequeue (Queue **front, Queue **rear)\n{\nint data;\n\nif (EmptyQueue (front))\n{\nprintf ("Queue Empty!&#92;n");\nexit (QUEUE_EMPTY);\n}\n\ndata = (*front)->data;\nif ((*front)->link == NULL)\n*front = *rear = NULL;\nelse\n*front = (*front)->link;\n\nreturn data;\n\n}\n\nint EmptyQueue (Queue **q)\n{\nif (*q == NULL)\nreturn TRUE_EMPTY;\n\nreturn FALSE_EMPTY;\n}
646616
class publication\n{\n   private :\n      char title[20];\n      float price;\n   public :\n      void getdata()\n      {\n          cin>>title;\n          cin>>price;\n      }\n};\nclass books :: public publication\n{\n   private :\n      int pagecount;\n   public :\n      void getdata()\n      {\n          cin>>pagecount;\n      }\n\n};\nclass tape :: public publication\n{\n   private :\n      int playing_time;\n   public :\n      void getdata()\n      {\n          cin>>playing_time;\n      }\n};
1065652
void main()\n{\ncout<<"no"<<"/t"<<"id.no"<<"/t"<<"name"<<"/t"<<"sex"<<"/t"<<"department";\ncout<<"1 001/98 sarafcomputerscience&#92;n";\ncout<<"your information";\ncout<<"your information";\ncout<<"your information";\ncout<<"your information";\n\n}\nif u want to get input at runtime try to input thr cin>> statement and get that output by cout statement
784164
sure you can use that syntax and it's correct this way:\nwrite(arraylist[x]);\nusualy this is used with a for clause\nfor i:=0 to n do\n write(arraylist[i]);\nbut if you put a pice of code when ur using this i can help you fix your errors.
1056055
1) You should try making a flow-chart to see the issues here...\n\n2) Your comparison:  if %1==%1 (and also for %2) will ALWAYS BE TRUE and will never get to parts of your code!