<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML xmlns="http://www.w3.org/TR/REC-html40" xmlns:o =
"urn:schemas-microsoft-com:office:office" xmlns:w =
"urn:schemas-microsoft-com:office:word"><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content=Word.Document name=ProgId>
<META content="MSHTML 6.00.5730.11" name=GENERATOR>
<META content="Microsoft Word 10" name=Originator><LINK
href="cid:filelist.xml@01C7000D.CBB378A0" rel=File-List><!--[if gte mso 9]><xml>
<o:OfficeDocumentSettings>
<o:DoNotRelyOnCSS/>
</o:OfficeDocumentSettings>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:WordDocument>
<w:SpellingState>Clean</w:SpellingState>
<w:GrammarState>Clean</w:GrammarState>
<w:DocumentKind>DocumentEmail</w:DocumentKind>
<w:EnvelopeVis/>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
</w:WordDocument>
</xml><![endif]-->
<STYLE>@font-face {
        font-family: Wingdings;
}
@page Section1 {size: 612.0pt 792.0pt; margin: 72.0pt 90.0pt 72.0pt 90.0pt; mso-header-margin: 35.4pt; mso-footer-margin: 35.4pt; mso-paper-source: 0; }
P.MsoNormal {
        FONT-SIZE: 12pt; MARGIN: 0cm 0cm 0pt; FONT-FAMILY: "Times New Roman"; mso-style-parent: ""; mso-pagination: widow-orphan; mso-fareast-font-family: "Times New Roman"
}
LI.MsoNormal {
        FONT-SIZE: 12pt; MARGIN: 0cm 0cm 0pt; FONT-FAMILY: "Times New Roman"; mso-style-parent: ""; mso-pagination: widow-orphan; mso-fareast-font-family: "Times New Roman"
}
DIV.MsoNormal {
        FONT-SIZE: 12pt; MARGIN: 0cm 0cm 0pt; FONT-FAMILY: "Times New Roman"; mso-style-parent: ""; mso-pagination: widow-orphan; mso-fareast-font-family: "Times New Roman"
}
A:link {
        COLOR: blue; TEXT-DECORATION: underline; text-underline: single
}
SPAN.MsoHyperlink {
        COLOR: blue; TEXT-DECORATION: underline; text-underline: single
}
A:visited {
        COLOR: purple; TEXT-DECORATION: underline; text-underline: single
}
SPAN.MsoHyperlinkFollowed {
        COLOR: purple; TEXT-DECORATION: underline; text-underline: single
}
SPAN.EmailStyle17 {
        COLOR: windowtext; FONT-FAMILY: Arial; mso-style-type: personal-compose; mso-style-noshow: yes; mso-ansi-font-size: 10.0pt; mso-bidi-font-size: 10.0pt; mso-ascii-font-family: Arial; mso-hansi-font-family: Arial; mso-bidi-font-family: Arial
}
SPAN.SpellE {
        mso-style-name: ""; mso-spl-e: yes
}
SPAN.GramE {
        mso-style-name: ""; mso-gram-e: yes
}
DIV.Section1 {
        page: Section1
}
</STYLE>
<!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
        {mso-style-name:"Table Normal";
        mso-tstyle-rowband-size:0;
        mso-tstyle-colband-size:0;
        mso-style-noshow:yes;
        mso-style-parent:"";
        mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
        mso-para-margin:0cm;
        mso-para-margin-bottom:.0001pt;
        mso-pagination:widow-orphan;
        font-size:10.0pt;
        font-family:"Times New Roman";}
</style>
<![endif]--></HEAD>
<BODY lang=EN-US style="tab-interval: 36.0pt" vLink=purple link=blue
bgColor=#ffffff>
<DIV><FONT size=2> Daca amesteci apelurile
de stream-uri C++ cu cele de C apar astfel de probleme deoarece au buffer-e
diferite.</FONT></DIV>
<DIV><FONT size=2> Daca nu dai cout.flush()
sau fflush(stdout) pot aparea iar output-uri amestecate.</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2> Daca nu ai facut asta,
nu stiu care e problema. :-D</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV style="FONT: 10pt arial">----- Original Message -----
<DIV style="BACKGROUND: #e4e4e4; font-color: black"><B>From:</B> <A
title=costinb@rdslink.ro href="mailto:costinb@rdslink.ro">Costin Boldisor</A>
</DIV>
<DIV><B>To:</B> <A title=so@cursuri.cs.pub.ro
href="mailto:so@cursuri.cs.pub.ro">so@cursuri.cs.pub.ro</A> </DIV>
<DIV><B>Sent:</B> Saturday, November 04, 2006 12:36 PM</DIV>
<DIV><B>Subject:</B> [SO] Curiozitate</DIV></DIV>
<DIV><BR></DIV>
<DIV class=Section1>
<P class=MsoNormal><FONT face=Arial size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">Am o <SPAN
class=SpellE>curiozitate</SPAN> in <SPAN class=SpellE>legatura</SPAN> cu o <SPAN
class=SpellE>problema</SPAN> <SPAN class=SpellE>pe</SPAN> care am <SPAN
class=SpellE>avut</SPAN>-o la <SPAN class=SpellE>tema</SPAN> 1 <SPAN
class=SpellE>pe</SPAN> win.<o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><SPAN class=SpellE><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">Problema</SPAN></FONT></SPAN> era ca <SPAN
class=SpellE>nu</SPAN> <SPAN class=SpellE>imi</SPAN> <SPAN
class=SpellE>trecea</SPAN> <SPAN class=SpellE>testele</SPAN> 1 <SPAN
class=SpellE>si</SPAN> 2 (<SPAN class=SpellE>restul</SPAN> <SPAN
class=SpellE>erau</SPAN> <SPAN class=GramE>passed <FONT face=Wingdings><SPAN
style="FONT-FAMILY: Wingdings; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-char-type: symbol; mso-symbol-font-family: Wingdings"><SPAN
style="mso-char-type: symbol; mso-symbol-font-family: Wingdings">J</SPAN></SPAN></FONT></SPAN>
)<o:p></o:p></P>
<P class=MsoNormal><SPAN class=SpellE><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">Cauza</SPAN></FONT></SPAN> era <SPAN
class=SpellE>urmatoarea</SPAN>: <SPAN class=SpellE>outputul</SPAN> <SPAN
class=SpellE>comenzilor</SPAN> era <SPAN class=SpellE>corect</SPAN> <SPAN
class=SpellE>dar</SPAN> se <SPAN class=SpellE>afisa</SPAN> <o:p></o:p></P>
<P class=MsoNormal><SPAN class=SpellE><SPAN class=GramE><FONT
face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">inainte</SPAN></FONT></SPAN></SPAN> <SPAN
class=SpellE>sa</SPAN> se <SPAN class=SpellE>afiseze</SPAN> <SPAN
class=SpellE>promptul</SPAN>. <SPAN class=SpellE>Adica</SPAN>:<o:p></o:p></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">/<SPAN
class=SpellE>cygdrive</SPAN>/e…<o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">CYGWIN_NT-5.1 <o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><SPAN class=SpellE><SPAN class=GramE><FONT
face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">costin</SPAN></FONT></SPAN></SPAN><o:p></o:p></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">> <o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">> <o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><SPAN class=SpellE><SPAN class=GramE><FONT
face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">Ordinea</SPAN></FONT></SPAN></SPAN><SPAN class=GramE>
<SPAN class=SpellE>aceasta</SPAN> de <SPAN class=SpellE>afisare</SPAN> <SPAN
class=SpellE>aparea</SPAN> <SPAN class=SpellE>numai</SPAN> <SPAN
class=SpellE>pe</SPAN> server, la mine <SPAN class=SpellE>mergea</SPAN> <SPAN
class=SpellE>bine</SPAN>.</SPAN><o:p></o:p></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><SPAN class=SpellE><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">Ideea</SPAN></FONT></SPAN> era ca <SPAN
class=SpellE>pe</SPAN> <SPAN class=SpellE>versiunea</SPAN> cu <SPAN
class=SpellE>probleme</SPAN> <SPAN class=SpellE>eu</SPAN> <SPAN
class=SpellE>afisam</SPAN> <SPAN class=SpellE>promptul</SPAN> cu:<o:p></o:p></P>
<P class=MsoNormal><FONT face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes">fprintf(stdout,<FONT
color=maroon><SPAN
style="COLOR: maroon">"%s"</SPAN></FONT>,s);<o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><SPAN class=SpellE><SPAN class=GramE><FONT
face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">iar</SPAN></FONT></SPAN></SPAN> <SPAN
class=SpellE>pe</SPAN> <SPAN class=SpellE>versiunea</SPAN> care a <SPAN
class=SpellE>luat</SPAN> <SPAN class=SpellE>testele</SPAN> 1 <SPAN
class=SpellE>si</SPAN> 2 <SPAN class=SpellE>afisez</SPAN> cu<o:p></o:p></P>
<P class=MsoNormal><FONT face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes">cout<<s.c_str();<o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">Care <SPAN class=SpellE><SPAN
class=GramE>este</SPAN></SPAN> <SPAN class=SpellE>ideea</SPAN>? <SPAN
class=SpellE>Implementarea</SPAN> <SPAN class=SpellE>comenzilor</SPAN> din <SPAN
class=SpellE>stdio.h</SPAN> <SPAN class=SpellE>si</SPAN> din <SPAN
class=SpellE>iostream</SPAN> <SPAN class=SpellE>nu</SPAN> <SPAN
class=SpellE>apeleaza</SPAN> <SPAN class=GramE>un</SPAN> <SPAN
class=SpellE>WriteFile</SPAN> <SPAN class=SpellE>sau</SPAN> <SPAN
class=SpellE>ceva</SPAN>?<o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN
style="FONT-SIZE: 12pt">Cum se <SPAN class=SpellE>poate</SPAN> inversa <SPAN
class=SpellE>ordinea</SPAN> <SPAN class=SpellE>textului</SPAN> <SPAN
class=SpellE>afisat</SPAN>, din moment <SPAN class=SpellE>ce</SPAN> <SPAN
class=SpellE><SPAN class=GramE>fprintf</SPAN></SPAN><SPAN
class=GramE>(</SPAN>..) <SPAN class=SpellE>este</SPAN> <SPAN
class=SpellE>sigur</SPAN> <SPAN class=SpellE>apelat</SPAN> <SPAN
class=SpellE>inainte</SPAN> de <SPAN
class=SpellE>CreateProcess</SPAN>(..)?<o:p></o:p></SPAN></FONT></P></DIV>
<P><FONT size=2></FONT></P></BODY></HTML>