f



c++ <vector> version of fortran "merge" or "where"

Hi,
I have several <vector>'s of the same length, with entries
as follows:

I=[0,3,6,0,5,3,0]
A=[1,2,3,4,5,6,7]
B=[2,3,4,5,6,7,8]

I want to use STL to make (I == 0) a mask to operate on the
elements of A and B, i.e. I want to do this:

for (int i=0;i<I.size();i++){
   if ( I[i] == 0 ){
      A[i] = 0;
      B[i] = 0;
   }
}

In fortran 90 it would be easy:
A = merge( 0, A, I==0 )
B = merge( 0, B, I==0 )

Can anybody point out how to do it in C++?  I don't see how
replace_if can do it.

Thanks in advance,
Sean Dettrick
0
sdettrick (26)
6/27/2003 10:20:00 PM
comp.lang.c++ 49423 articles. 7 followers. Post Follow

1 Replies
617 Views

Similar Articles

[PageSpeed] 43

"Sean Dettrick" <sdettrick@hotmail.com> wrote in message
news:c233c3ea.0306271420.49a80c4@posting.google.com...
> Hi,
> I have several <vector>'s of the same length, with entries
> as follows:

std::vector<int>'s I assume?
>
> I=[0,3,6,0,5,3,0]
> A=[1,2,3,4,5,6,7]
> B=[2,3,4,5,6,7,8]
>
> I want to use STL to make (I == 0) a mask to operate on the
> elements of A and B, i.e. I want to do this:
>
> for (int i=0;i<I.size();i++){
>    if ( I[i] == 0 ){
>       A[i] = 0;
>       B[i] = 0;
>    }
> }
>
> In fortran 90 it would be easy:
> A = merge( 0, A, I==0 )
> B = merge( 0, B, I==0 )
>
> Can anybody point out how to do it in C++?  I don't see how
> replace_if can do it.

replace_if could do it with some manipulation: form 2
std::vector<std::pair<int,int> >, one of corresponding elements of A and I,
the other of corresponding elements of B and I, and have your predicate
replace the changed elements with pair<int,in>(0,0), then write the A or B
elements back into their vectors.  It really isn't the right algorithm for
this, though.  The replace algorithms do the test on the same container
whose elements they change, but you want to change elements of a different
container than the one that has the test values.  You'd be better off using
std::transform.  The standard library algorithms are rather elemental though
general, so you will not find highly specialized usages like you've written
above for F90.  Also, C++ doesn't have expression lambdas like the "I==0"
you wrote; predicates and operators for the standard algorithms are done as
explicit functions or functors. So you need an operator which will do the
test and return either 0 or the original value: a simple function will do:

int trans_op(int orig,int test){ return test?orig:0;}

and then use the binary-operator form of std::transform:

 std::transform(A.begin(),A.end(),I.begin(),A.begin(),trans_op);
 std::transform(B.begin(),B.end(),I.begin(),B.begin(),trans_op);

-- Hiram Berry


0
burningb (2)
6/28/2003 3:36:09 AM
Reply:

Similar Artilces:

What is the difference between "Borland C++" and "Turbo C++"?
...

Urgent JAVA Requirement in """"""NEW YORK"""""""""
Hello Partners, How are you ? Please find the requirement below. Location : NY Duration : 8 mnths Rate :Open Job description: Java/J2EE Web Service Developer =B7 (4+ years of application development experience in Java/J2EE and Web service technologies. =B7 Experience with spring & Hibernate. =B7 Experience with J2EE Application Server (preferably Web logic). =B7 Preferable Aqua logic DSP Experience =B7 Preferable Sonic ESB Composite Service experience Experience working in UNIX environment. Good working knowledge of Oracle RDBMS and PL/SQL) Note : Please send your updated resume along with contact no to Karthik@bhaninfo.com. Thanks & Regards Karthik BhanInfo karthik@bhaninfo.com # 1572, 7 th Floor Suites, 1 Blue Hill Plaza Pearl River,NY-10965 www.bhaninfo.com ...

Transform string : "c;b;a;e;d" -> "a;b;c;d;e" ?
Thank's for your help ! Indrid On Mon, 11 Jul 2005 22:47:26 -0400, "Indrid Colt" <indrid@colt.com> wrote: Well, you could use the Split function to create an array with 5 elements. Then use any suitable sorting algorithm to sort these items. Then use the Join function to stitch the elements back together. -Tom. >Thank's for your help ! > > >Indrid > Tom van Stiphout <no.spam.tom7744@cox.net> wrote in news:fkc6d1thuadliq28absbqrjpc535d4m1p0@4ax.com: > On Mon, 11 Jul 2005 22:47:26 -0400, "Indrid Colt" > <indrid@colt.com> wrote: > > Well, you could use the Split function to create an array with 5 > elements. Then use any suitable sorting algorithm to sort these > items. Then use the Join function to stitch the elements back > together. For a case where the values are all one character, why not just use a ReverseString() function like the one posted after my sig? -- David W. Fenton http://www.bway.net/~dfenton dfenton at bway dot net http://www.bway.net/~dfassoc Public Function ReverseString(strInput As String) As String Dim i As Integer Dim tmpString As String Dim tmpOutput As String tmpString = strInput For i = 1 To Len(strInput) tmpOutput = tmpOutput & Right(tmpString, 1) tmpString = Left(tmpString, Len(tmpString) - 1) Next i ReverseString = tmpOutput End Function David W. Fenton wrote: > For a case where...

What is the difference between "=>" and "->" operators?
Morning, I'm currently working my way through a series of tutorials from IBM's developer network called "Cook up Web sites fast with CakePHP". The XAMPP 1.4.9 development platform consists of PHP Version 5.0.2, MySQL 3.23.57. Here is an excerpt of code provided in the tutorial, which is used to create a model: <?php class Dealer extends AppModel { var $name = 'Dealer'; var $hasMany = array ('Product' => array( 'className' => 'Product', 'conditions'=>, 'order'=>, 'foreignKey'=>'dealer_id') ); } ?> Eclipse produces an error underneath the comma directly after the 'conditions' field, which says: "Parse error: "Static/scalar constant expected."" I changed the code above, got it working and continued through the tutorial: <?php class Dealer extends AppModel { var $name = 'Dealer'; var $hasMany = array ( "Product" => array("className","Product","conditions","order","foreignKey","dealer_id")); } ?> The system works fine until I used Bake to implement an ACL. Each time a new user registers, a rule is supposed to be enterred into the db which defines what access level they have, but it doesn't work. When a new user registers a new record should appear in the ACL tables. This is the only thing that I can think might have caused a problem. What is the differen...

"ClientConn", "ClientRate" and "Connect"
Hello. Is a ratecontrol and conncontrol features not work for networks described via connect in access ? For example: -----part of /etc/mail/access----- ClientConn:192.168.1 1 ClientRate:192.168.1 1 Connect:192.168.1 RELAY ----------------------------------- -- Regards, Sergey Sergey wrote: > Is a ratecontrol and conncontrol features not work for networks described via connect in access ? > For example: > ClientConn:192.168.1 1 > ClientRate:192.168.1 1 > Connect:192.168.1 RELAY See cf/README. Connect:cyberspammer.com REJECT Connect:TLD REJECT Connect:192.168.212 REJECT would refuse mail from spammer@aol.com, any user from cyberspammer.com (or any host within the cyberspammer.com domain), any host in the entire top level domain TLD, 192.168.212.* network, >.. Hmm, for ClientConn and ClientRate it doesn't seem to be documented. The sendmail X documentation has this explanation: .... icr:10 5 Note, however, that the limits apply only to single IP addresses, they are not aggregated for nets. That is, for the example every single host in the IP net 10.x.y.z can have a maximum incoming connection rate of 5 messages per minute. -- Note: please read the netiquette before posting. I will almost never reply to top-postings which include a full copy of the previous article(s) at the end because it's annoying, shows that the poster is too lazy to trim his arti...

Is there a "break" "continue" equivalent in the "for" or "while" statement in SKILL?
Thank you! madhero wrote, on 07/03/08 09:42: > Thank you! Not directly, but see: http://tinyurl.com/69wte8 http://tinyurl.com/6ycdbn for two related threads in this group. Regards, Andrew. ...

Replacing "/[^>][\n\r]+/" with "<br />\n"
Hi all, I would like to replace line breaks such '[\n\r]+' with '<br />'. Easy task. Problems start when I try to only replace lines that do not end with HTML tags. I tried preg_replace("/[^>][\n\r]+/", "<br />\n") but this does not seem to work. An example to better understand what I would like to achieve: first line <title>Title</title> third line should give: first line<br /> <title>Title</title> third line<br /> Any help would be grateful appreciated. Thanks and have a nice day, christian ribchr00@stud.unibas.ch wrote: > Hi all, > > I would like to replace line breaks such '[\n\r]+' with '<br />'. Easy > task. Problems start when I try to only replace lines that do not end > with HTML tags. > I tried preg_replace("/[^>][\n\r]+/", "<br />\n") but this does not > seem to work. I've been guilty of gymnastics with regexes in the past, but these days I prefer the simple, readable route: //$line = "<test>\n"; $line = "test\n"; if( !preg_match( '/>[\n\r]+$/', $line ) ) { $line = preg_replace("/[\n\r]+$/", "<br />\n", $line ); } echo $line; Not tested, but it looks about right. :o) -- The email address used to post is a spam pit. Contact me at http://www.derekfountain.org : <a href="http://www.derekfountain.org/">Derek Founta...

Definition of "shall", "should", "must", etc.
Is there a written standard anywhere that defines specification terms like "shall" and "should" and "must"? I've run into a number of projects where, in particular, "shall" / "must" / "will" are all used interchangeably. Your thoughts... "C. J. Clegg" <reply.to.newsgroup@nospam.no> wrote in message news:jbsbh19g228ne84213f8kh0uvccj5ie6sg@4ax.com... > > Is there a written standard anywhere that defines specification terms > like "shall" and "should" and "must"? > > I've run into a number of projects where, in particular, "shall" / > "must" / "will" are all used interchangeably. > When in doubt, place an explicit statement that serves to indicate the interpretation that will be used (make certain it is not inconsistent with the customers rules and regulations) > Your thoughts... C. J. Clegg wrote: > Is there a written standard anywhere that defines specification terms > like "shall" and "should" and "must"? > > I've run into a number of projects where, in particular, "shall" / > "must" / "will" are all used interchangeably. > > Your thoughts... oh ...the beauty of google and having worked in telecomms where this knowledge is an (unfortunate) must (no pun intended) http://standards.ieee.org/guides/style/section...

what is the difference between "tsu", "su" and "sudo"?
Hi all I needed to ask a question about the Linux commands used for getting root access. The question is, what is the difference between "tsu", "su", and "sudo"? I am mainly interested about the "tsu" command regarding which there seems to be very little documentation. What is the benefit in using e.g. "tsu" rather than "su"? And are there other ones besides these 3? (If yes, any pointers to a website discussing all of them would be appreciated.) Thanks in advance, JJ <santa@temporaryinbox.com> writes: >Hi all >I needed to ask a question about the Linux commands used for getting >root access. >The question is, what is the difference between "tsu", "su", and >"sudo"? Never heard of tsu. Not on my system. >I am mainly interested about the "tsu" command regarding which there >seems to be very little documentation. So for something like securly logging in why in the world would you use something for which you can find no docs? You look up the barrel of guns to see if they are loaded while you pull the trigger as well? >What is the benefit in using e.g. "tsu" rather than "su"? For something like su, I would say there is no benefit. >And are there other ones besides these 3? (If yes, any pointers to a >website discussing all of them would be appreciated.) ???? W...

gem "before" and "after" filters?
--nextPart1495269.fW4IQGULCc Content-Type: text/plain; charset="iso-8859-15" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Hello, I am trying to build a gem and I need to do some pre-processing (creating a= =20 file) before I can create my rdoc's and some cleaning (erasing that file)=20 after I create it. Running something before building the gem is easy (just specify it in the=20 gemspec before the Gem::Specification.new), but how do I run something=20 afterwards? (writing the code at the end or after the end of the=20 Gem::Specification does not work, because that code is run before the gem i= s=20 built) Thank you. =2D-=20 Pau Garcia i Quiles http://www.elpauer.org (Due to the amount of work, I usually need 10 days to answer) --nextPart1495269.fW4IQGULCc Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.2 (GNU/Linux) iD8DBQBFNWll/DzYv9iGJzsRAu9mAKCZiWfrT8/LEKCcYItqbZJHtWbyCQCg0F9E IBr0fPsFyvUuUPO1VGD6ZhA= =Ge37 -----END PGP SIGNATURE----- --nextPart1495269.fW4IQGULCc-- On 10/17/06, Pau Garcia i Quiles <pgquiles@elpauer.org> wrote: > I am trying to build a gem and I need to do some pre-processing (creating a > file) before I can create my rdoc's and some cleaning (erasing that file) > after I create it. > > Running something before building the gem is easy (just specify it in the > gemspec before the Gem::Specification.new), but how do I run something &...

"refreshdata" against "set"
Which one is better, "refreshdata" or "set"? Simply by looking at the code I've noticed that refreshdata does: 1) Finds all the properties of the object which end with 'DataSource' 2)Evaluates all of the relevant variables in the upper workspace 3) Does set(h,....) It looks like there is no advantage in using refreshdata, as it ultimately calls set, but does bunch of other operations. In my GUI, I've implemented polygon movement with both, and using directly "Set" is much smoother. Please correct me if I'm wrong. ...

Matching "Goto" for "From"
Hello, i am a newer ,this is a problem when i learn a example, when i simulated it ,there always are warnings such as: Warning: Matching "Goto" for "From" 'untitled/DC Machine/iA/source' not found. Warning: Matching "Goto" for "From" 'untitled/DC Machine/iF/source' not found. Warning: Matching "From" for "Goto" 'untitled/DC Machine/FCEM/Goto' not found. Warning: Matching "From" for "Goto" 'untitled/DC Voltage Source/Goto' not found. Warning: Using a default value of 0.02 for maximum step size. The simulation step size will be limited to be less than this value. now, i can not sovle the problem, so i need you help , thank you ! ...

Invalid use of "." "!"
In writing a sql statement I get the error "invalid use of "." "!"......... this is apparently coming because the where clause of the sql statemt refers to a combo box with sales persons names in it. All the names are listed first initial followed by a "." and last name. I am assuming the error i am getting is coming from the "." in the combo box. How do I get around the invalid use of the "." ? Thanks Never mind..... didnt have enough quotation marks. "Learning" <texson552000@yahoo.com> wrote in message news:DQELg.10308$o42.364@tornado.texas.rr.com... > In writing a sql statement I get the error "invalid use of "." "!"......... > this is apparently coming because the where clause of the sql statemt refers > to a combo box with sales persons names in it. All the names are listed > first initial followed by a "." and last name. I am assuming the error i am > getting is coming from the "." in the combo box. > > How do I get around the invalid use of the "." ? > > Thanks > > ...

When to use "." and when to use "!"
I'm still confused about this and I can't find anywhere that explains it properly. I have the MS book "Access 2003" in front of me and I'm reading Part 5 about VB and so on. It's telling me about how to refer to a specific database and has the example:- Dim dbMyDb As DAO.Database Set dbMyDb = DBEngine.Workspaces(0).Databases(0) but, but, but, but - what do those dots (periods, full stops, call them what you will) mean? (OK, it appears to be the same usage as C/C++/Java when referring to class/structure members, but I wish it would tell me that somewhere) Why are there dots used in referring to object members in this case but when referring to controls on forms (for example) one uses "!". Surely there must be somewhere that helps one understand this basic syntax. -- Chris Green Generally, a dot exposes properties and methods and a bang (!) exposes members of a collection. So forms!frmMyForm.Visible refers to the visible property of frmMyForm, which is a member of the forms collection. What makes this harder (or easier, depending on your perspective) to grasp, is that Access has gotten more and more forgiving about using the "wrong" notation. usenet@isbd.co.uk wrote in news:44316bba.0@entanet: > I'm still confused about this and I can't find anywhere that explains > it properly. > > I have the MS book "Access 2003" in front of me and I'm reading Part 5 > about VB and so on....

"Ritual" is "MumboJumbo"
Well it looks as if Ritual has been "saved". Don't know if we'll ever get to see a SiN Episodes 2 or another Painkiller, but at least this bunch of talented people have jobs in the industry still. MumboJumbo are better known for casual games like Luxor. Let's hope they decide to branch out a bit and venture into the Action/FPS games market. Somehow I can't quite see myself getting over excited at the prospect of "Super Collapse: Episode 3- Revenge of the Orange and Blue Marbles". http://www.bluesnews.com/cgi-bin/board.pl?action=viewthread&threadid=74809 -- Rob Rob wrote: > Well it looks as if Ritual has been "saved". Don't know if we'll ever > get to see a SiN Episodes 2 or another Painkiller, but at least this > bunch of talented people have jobs in the industry still. > > MumboJumbo are better known for casual games like Luxor. Let's hope > they decide to branch out a bit and venture into the Action/FPS games > market. > > Somehow I can't quite see myself getting over excited at the prospect > of "Super Collapse: Episode 3- Revenge of the Orange and Blue > Marbles". > > http://www.bluesnews.com/cgi-bin/board.pl?action=viewthread&threadid=74809 Oh you bastard, and RIGHT on the exact same minute as me! :) "Rob" <noemailformethx@jsjsaiiowppw.invalid> wrote in message news:5rjfr2d2dhnmjmo4k74p1kl3qrhmnnpv46@4ax.com... > > W...

XML problem with special characters like "<" and ">"
Hello! I prepare my XML document like this way: ------------------------------------------------------- PrintWriter writer; Document domDocument; Element domElement; // Root tag domElement = domDocument.createElement ("ROOT_TAG"); domDocument.appendChild (domElement); // XML from an external source as a "String" Text data = domDocument.createTextNode (externalXML); domElement.appendChild (data); writer.println (...); ------------------------------------------------------- As you can see, I create a normal Root-Node and then I get an XML stream from an external source. For the external XML I use the function "createTextNode" because it is a text in some way. The problem is the output when I write all together to the PrintWriter object. It looks like this for this example: -------------------------------------------------------------- <?xml version="1.0" encoding="UTF-8"?> <ROOT_TAG> &lt;DATA&gt; &lt;AFL&gt; &lt;AFLNR&gt;XX&lt;/AFLNR&gt; &lt;BENENNUNG&gt;MY TEST&lt;/BENENNUNG&gt; &lt;LA_VER&gt;&lt;/LA_VER&gt; &lt;FA_KR&gt;&lt;/FA_KR&gt; &lt;POL_COD&gt;&lt;/POL_COD&gt; &lt;FA_KZ&gt;&lt;/FA_KZ&gt; &lt;G_KZ&gt;&lt;/G_KZ&gt; &lt;AFL_KZ&gt;1&lt;/AFL_KZ&gt; &lt;/AFL&gt; &lt;/DATA&gt; </ROOT_TAG> -...

[News] [Rival] Microsoft Has "Critical", "Critical", "Critical", "Critical", "Critical", and "Critical" Flaw
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 MS fuels up five critical Windows fixes ,----[ Quote ] | Microsoft plans to release five critical update bulletins next Tuesday, all | critical, in the September edition of its regular Patch Tuesday update cycle. `---- http://www.reghardware.co.uk/2009/09/04/ifa_lg_pdp/ Recent: Microsoft rejects call to fix SQL password-exposure risk ,----[ Quote ] | Microsoft is butting heads with a company that provides software for database | security over a weakness in SQL Server that can expose user passwords to | anyone with administrative access to the program. `---- http://www.theregister.co.uk/2009/09/02/sql_server_password_exposure/ Related: Bots rule in cyberspace ,----[ Quote ] | USA TODAY REPORTS that on an average day, 40 per cent of the 800 million | computers connected to the Internet are bots used to send out spam, viruses | and to mine for sensitive personal data.   `---- http://www.theinquirer.net/gb/inquirer/news/2008/03/17/bots-rule-cyberspace http://www.usatoday.com/tech/news/computersecurity/2008-03-16-computer-botnets_N.htm Botnets Running Rampant ,----[ Quote ] | How much money is being stolen by cybercriminals? No one knows, and no one | even knows how to go about coming up with that number, IronPort's Peterson | said.   `---- http://www.pcworld.com/businesscenter/article/144489/botnets_running_rampant.html -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAkq...

Need help to read the following line : <?xml version="1.0" encoding="UTF-8"?>
I'm using the following parser : SAX2XMLReader (Apache sax parser). My class is derived from DefaultHandler object and i'm overwriting the following methods : 1. void processingInstruction (...); 2. void docPI (...); 3. void elementDecl (...); .... but no one of these function is being called by the parser. I'm also setting the following handlers : parser->setContentHandler(this); parser->setErrorHandler(this); parser->setLexicalHandler(this); parser->setDeclarationHandler(this); parser->setDTDHandler(this); Does anyone can tell me how can i extract these tags?? (version and encoding). thanks. ...

Dijkstra's "Enumeration" = "Metrics" his "Abstraction" = "Quality"
"Enumerative reasoning is only an adequate mental tool under the severe boundary condition that we only use it very moderately. We should appreciate abstraction as our main mental technique to reduce the demands made upon enumerative reasoning." ~ EW Dijkstra This is critically decisive because Dijkstra is saying that in most *software engineering" contexts, most of the time, abstraction is key relative to "metrics", the numerical, the quantitative. It is a TOWWWEEERRRING, grand slam "home run". It is of Doug William's 3-4 perfectly pitched Super Bowl touchdowns. It is growth in insight after Dijkstra one of THE very best ran into major impasses attempting to drive development with metrics. His insight is that ABSTRACTION should "lead" the way. While there is the dialectic: metrics<=>abstraction The predominant factor to engage and lead software engineering by is "abstraction". So notation wise better: metrics<=>abstraction* And to denote analyzing or summarizing the dialectic applied in whatever context, from point 'a' to 'b': a,b{ metrics<=>abstraction* Discrete points: a,b; l,q{ metrics<=>abstraction* Have at your own meaningful fun! Elliott -- Global Plans + IID = part of an optimal approach On Wed, 4 Feb 2004 23:36:17 -0500, "Universe" <universe@tAkEcovadOuT.net> wrote: >"Enumerative reasoning is only an adequate mental tool und...

=Iff(([Me]![Gender])="M","Male","Female")
Thanks in Advance! ... I have two textboxes: 1 is visible (and gets its value based on the invisible textbox and displays either "Male" or "Female", and needs to display either male of female based on the value that comes up in the tables record as "M" or "F". I tried: =Iff(([Me]![Gender])="M","Male","Female") 'the [Me] is form, [Gender] is the textbox name and this does not work. Is my syntax wrong or can I just have one box and its displayed value display "Female" if the record says "F"? Thanks! Brian When you say it doesn't work, do you mean the visible text box is empty? Or, does it display an error? Out of curiousity, why are you using two text boxes? I think it might be simpler to use a single combo box. Make its properties like so: Control Source: Gender Row Source Type: Value List Row Source: "M";"Male";"F";"Female" Column Count: 2 Column Heads: No Column Widths: 0" Bound Column: 1 This will give you a drop down list with two rows. Since the Column Count is 2, the "M" and "Male" values are the two columns for the first row and the "F" and "Female" are the two columns for the second row. Setting the Column Width to 0" means the first column will not be displayed but since it's the Bound Column, the "M" and "F" will be used as the value of...

new at "awk.info": SQL Awk; embedding Awk in "C"; and more
Here are the recent updates to http://awk.info . (For all updates to awk.info, subscribe to http://tinyurl.com/rss4awk. To contribute to awk.info, see http://awk.info/?contribute .) ----------------------------------------------------------- NEWS Inteview with Aharon Robbins. - http://awk.info/?news/robbinsTalks Ed Morton shows how to print ranges within an input file. - http://awk.info/?tip/printranges Janis Papanagnou shows how to use header names to reference column data. - http://awk.info/?tip/readheaders Tibor Palinkas shows how to embed Awk inside "C". - http://awk.info/?news/libmawk ----------------------------------------------------------- UPDATES Panos Papadopoulos has moved Spawk (SQL+AWK) to GoogleCode. - http://awk.info/?tools/spawk-in-googlecode ----------------------------------------------------------- PAGE OF THE MONTH Google Analytics tells us that awk.info's pages of the month are all our tutorial material: http://awk.info/?Learn Yes, it's true: the Netizens wants to learn Awk. ----------------------------------------------------------- MOST AWK-ISH CITY IN THE WORLD The most Awk-loving city in the world is Athens, Greece. Residents of that city visited awk.info more than anywhere else in the world. Also, Athens' love of Awk is increasing. The August visits have increased a massive 181% from the previous month. Now let's see if I can say this next bit correctly: =C1=E3=E1=F0=E7=F4=DD =C1=E8=DE=ED=E1, =CA=F1=E1=...

what does "!" do here?
#define HALT __asm CLRA; __asm SWI ! {A}, {A+HX+SR}; this is from Metrowerks hidef.h to define macros for HC08 microcontroller. what does "!" do here? ...

New to MATLAB, would like to know difference between "mbuild" and "mex" for c++ interface
Hi I am new to using MATLAB and I need to call some functions from a MATLAB program in a standalone C++ app. I am hoping if someone can tell me what is the difference between using mbuild vs mex options ? Thanks in advance John ...

Should I use "SERVER_NAME" or "HTTP_HOST"
After reading the site: http://shiflett.org/blog/2006/mar/server-name-versus-http-host Is that mean we should better use the 'SERVER_NAME' instead of "HTTP_HOST"? howa wrote: > After reading the site: http://shiflett.org/blog/2006/mar/server-name-versus-http-host > > Is that mean we should better use the 'SERVER_NAME' instead of > "HTTP_HOST"? Well it would depend on the context, wouldn't it? Hugh Oxford wrote: > howa wrote: > > After reading the site: http://shiflett.org/blog/2006/mar/server-name-versus-http-host > > > > Is that mean we should better use the 'SERVER_NAME' instead of > > "HTTP_HOST"? > > Well it would depend on the context, wouldn't it? I have multiple domain listening on the same IP/port. So my php need to find out which domain user is requesting for. So should I use which of them is more reliable/secure? howa wrote: > > Hugh Oxford wrote: >> howa wrote: >>> After reading the site: http://shiflett.org/blog/2006/mar/server-name-versus-http-host >>> >>> Is that mean we should better use the 'SERVER_NAME' instead of >>> "HTTP_HOST"? >> Well it would depend on the context, wouldn't it? > > I have multiple domain listening on the same IP/port. So my php need > to find out which domain user is requesting for. > So should I use which of them is more reliable/secu...

Web resources about - c++ <vector> version of fortran "merge" or "where" - comp.lang.c++

Resources last updated: 3/30/2016 11:50:10 AM