text
stringlengths
0
30.5k
title
stringclasses
1 value
embeddings
listlengths
768
768
marginTop: "10px", <- remove comma here }, "fast"); }); ``` Look after both of the marginTop you have a comma but no more properties. Remove them both.
[ -0.2246914505958557, 0.05483733490109444, 0.7372788190841675, -0.14944790303707123, -0.12333670258522034, 0.12467727810144424, -0.07076122611761093, -0.09294727444648743, -0.08808115869760513, -0.5790902376174927, -0.4003975987434387, 0.6322553753852844, -0.1974061131477356, -0.26878696680...
We have 15 projects in our development environment. Some are test projects, most are libraries, some are 'final' executables that can actually run, and some are setup projects. Most of the time, I only want to build those 'final' executables and their respective libraries, and let the setup project only be run when w...
[ 0.6783726811408997, 0.11454137414693832, -0.04960888624191284, 0.18734046816825867, 0.43346068263053894, 0.13820190727710724, 0.2758203446865082, -0.037863750010728836, -0.0647694393992424, -0.6240431666374207, -0.12312361598014832, 0.6245436668395996, 0.052363209426403046, 0.1605154573917...
us down). To reiterate: I can build just fine, and it will just build up to the appropriate point. If I choose start/continue, however, the setup projects get built, even though I'm not in the setup projects. So how do I remove my setup projects from the build tree? They're in the build order, but they're not depende...
[ 0.4232105612754822, -0.2018771767616272, 0.6667223572731018, 0.03608096390962601, 0.3858833312988281, -0.2658122777938843, 0.45257142186164856, -0.15943120419979095, -0.45199474692344666, -0.7911707758903503, -0.27841997146606445, 0.7746068835258484, -0.18293939530849457, 0.088941693305969...
way you could have two configurations: "Debug" and "Debug with Build Projects". --- To do this, right click on the Solution, choose Properties, Configuration Properties. If you want to make a new configuration, choose "Configuration Manager..." and create the new configuration, otherwise just edit one of your current...
[ 0.37215107679367065, -0.25736549496650696, -0.07328943908214569, 0.26842328906059265, 0.3268924951553345, -0.09820595383644104, 0.12742651998996735, -0.14312385022640228, -0.2428291290998459, -0.9465103149414062, -0.08498336374759674, 0.7521663904190063, -0.12542179226875305, 0.26324734091...
How do you import an SSL certificate created by java into a project in Eclipse? Probably you want to import a "fake" SSL cert in JRE's trustcacerts for avoiding not-a-valid-certificate issues. Isn't it? As Jon said, you can do the job with [keytool](http://java.sun.com/j2se/1.5.0/docs/tooldocs/solaris/keytool.html): ...
[ 0.25268736481666565, -0.01337815448641777, 0.22766047716140747, 0.15434712171554565, -0.13353027403354645, -0.4317992031574249, 0.21759404242038727, 0.038524068892002106, -0.11055801063776016, -0.7993853092193604, -0.32123249769210815, 0.4565195143222809, -0.22165067493915558, -0.389030843...
Consider this... I am writing a class named Cache which will accept either a path to a file/url or a string. I am going to use PHP's functions such as `parse_url()` and `is_file()` to determine which input I am receiving. here is my example, in PHP ``` class Cache { public function __construct($pathUriOrString) {...
[ 0.14158779382705688, 0.06781846284866333, 0.26862257719039917, 0.007529071066528559, -0.2610253095626831, -0.03007693588733673, 0.04498680680990219, -0.11997600644826889, 0.13046863675117493, -0.6629775166511536, 0.07776714116334915, 0.30834585428237915, -0.44693508744239807, 0.16790971159...
receives one argument (a path) or 2 arguments (a width and height). So, am I on the right track, and if so, what is best practice for naming an argument which takes different inputs (and won't confuse another developer down the track?) Could you possibly call the variable $resourcelocation and document it accordingly,...
[ -0.02446483075618744, -0.08644238114356995, 0.2971154749393463, 0.027333559468388557, -0.1855863481760025, 0.24168260395526886, 0.11524712294340134, -0.26245900988578796, -0.01169530302286148, -0.5593852996826172, 0.1146504208445549, 0.675000786781311, -0.08485519140958786, 0.0164349395781...
If it matches neither of the supported argument types then you should throw an error for an illegal parameter. The class declaration is fine (but missing an opening bracket) btw...
[ 0.3380676209926605, -0.016965948045253754, -0.012535776011645794, 0.049440253525972366, 0.0596601665019989, -0.3748791515827179, 0.4912552535533905, -0.2764562964439392, -0.12401537597179413, -0.1297236531972885, -0.1858549267053604, 0.6953617334365845, -0.18053284287452698, -0.02876930497...
I have very large images (jpg) and i want to write a csharp program to loop through the files and reduce the size of each image by 75%. I tried this: ``` Image thumbNail = image.GetThumbnailImage(800, 600, null, new IntPtr()); ``` but the file size is still very large. Is there anyway to create thumbnails and have...
[ 0.2625161111354828, 0.02543381042778492, 0.6895561218261719, -0.10601192712783813, 0.027758628129959106, 0.17899759113788605, 0.19544905424118042, -0.5154640078544617, -0.15774625539779663, -0.6387383937835693, -0.034792616963386536, 0.4749631881713867, -0.34508442878723145, 0.099706307053...
foreach (ImageCodecInfo encoder in ImageCodecInfo.GetImageEncoders()) if (encoder.MimeType == mimeType) return encoder; throw new ArgumentOutOfRangeException( string.Format("'{0}' not supported", mimeType)); } ``` Usage: ``` Image myImg = Image.FromFile(@"C:\Test.jpg"); CompressAndSav...
[ 0.21155725419521332, 0.12884941697120667, 0.6547307372093201, -0.15165720880031586, 0.15795215964317322, 0.25258079171180725, 0.39782267808914185, -0.5154500007629395, 0.09585470706224442, -0.8416037559509277, -0.14538058638572693, 0.6712713837623596, -0.30916211009025574, -0.0896781682968...
parameters.Param[0] = new EncoderParameter(Encoder.Quality, quality); img.Save(fileName, GetCodecInfo("image/jpeg"), parameters); } ``` Usage: ``` Image myImg = Image.FromFile(@"C:\Test.jpg"); myImg.SaveCompressed(@"C:\Test2.jpg", 10); ```
[ 0.26744523644447327, -0.05906559154391289, 0.5981798768043518, 0.0232929065823555, 0.03832833096385002, 0.35756275057792664, 0.08475954085588455, -0.5013762712478638, -0.281497061252594, -0.7077639698982239, -0.22350342571735382, 0.5000149607658386, -0.3442390263080597, -0.0237332433462142...
I'm just getting into Markdown and think it's the bee's knees. I'm working in ASP.NET (MVC) and am wondering if there are any good .NET libraries for Markdown, and am also curious how SO renders it on the fly. It must be a JavaScript library. StackOverflow uses [**Attacklab**](http://attacklab.net/)'s [**WMD**](http://...
[ 0.024631503969430923, 0.13686837255954742, 0.6438044905662537, -0.41097527742385864, -0.24634259939193726, -0.03100193291902542, 0.22167986631393433, -0.23150013387203217, -0.08662548661231995, -0.7626355886459351, 0.0635170191526413, 0.5141331553459167, -0.27751174569129944, -0.0997171774...
jWmd.rules("add", { required: true, minlength: 10 }); ```
[ 0.2368316948413849, -0.07759968936443329, 0.3235108256340027, -0.207148015499115, 0.05680922046303749, -0.24453702569007874, 0.5391673445701599, -0.1974576711654663, -0.08514251559972763, -0.3323758840560913, -0.3548106253147125, 0.4838816821575165, -0.08716210722923279, 0.1090718507766723...
I am setting a style for the Window in the `App.xaml` like such: ``` <Application x:Class="MusicRepo_Importer.App" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:System="clr-namespace:System;assembly=mscorlib" StartupUri="TestMaster.xaml">...
[ 0.2783639430999756, 0.15626272559165955, 0.659104585647583, -0.23158663511276245, -0.1791078895330429, 0.06764183938503265, 0.1877250373363495, -0.2545309066772461, -0.3190530240535736, -0.5218803286552429, -0.17902062833309174, 0.408088743686676, -0.34152960777282715, 0.1720411777496338, ...
each window like the following.. In app.xaml/resources.. ``` <Style x:Key="MyWindowStyle" TargetType="Window"> <Setter Property="WindowStyle" Value="None"></Setter> </Style> ``` Then in the window.xaml.. ``` <Window x:Class="MusicRepo_Importer.MyWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml...
[ -0.11740687489509583, 0.02121938392519951, 0.8505297303199768, -0.06112755462527275, -0.23939599096775055, -0.0015934581169858575, -0.048922859132289886, -0.1814199835062027, -0.13701395690441132, -0.5775769352912903, -0.22379928827285767, 0.5927295684814453, -0.20576581358909607, 0.173249...
However derived types > will not... it seems. <Style > TargetType="{x:Type Window}"> will not > work for all your custom > derivations/windows. <Style > TargetType="{x:Type local:MyWindow}"> > will apply to only MyWindow. So the > options are > > > Use a Keyed Style that you specify as > the Style property of...
[ 0.5086939334869385, -0.14769594371318817, 0.794219970703125, 0.12732383608818054, -0.027987100183963776, -0.1286783218383789, 0.1702994555234909, -0.5461143851280212, 0.03891442343592644, -0.6174229383468628, -0.2654556930065155, 0.5896280407905579, -0.20259897410869598, 0.0894254073500633...
I'm not sure how to write this query in SQL. there are two tables ``` **GroupRecords** Id (int, primary key) Name (nvarchar) SchoolYear (datetime) RecordDate (datetime) IsUpdate (bit) **People** Id (int, primary key) GroupRecordsId (int, foreign key to GroupRecords.Id) Name (nvarchar) Bio (nvarchar) Location (nvarcha...
[ 0.021318376064300537, 0.21224822103977203, 0.4889555275440216, 0.07726555317640305, -0.03354983404278755, -0.0428377203643322, 0.12210473418235779, -0.1844794750213623, -0.444841593503952, -0.5345022678375244, -0.0421772226691246, 0.12448254972696304, 0.23103630542755127, 0.343879789113998...
forum post link) that appears to be what you are looking for. Some of the examples are using the Transient lifecycle but I think it will work with Singleton also. The main pay-off of the [forum post](http://forum.castleproject.org/viewtopic.php?p=14725&sid=f94e87a29e0f4b3c65c62ccd67a064b7) is: ``` container.Registe...
[ -0.12740810215473175, -0.08274678140878677, 0.8760501742362976, 0.06735992431640625, -0.051709868013858795, -0.18340472877025604, 0.2793002128601074, 0.15871961414813995, -0.3710842430591583, -0.6877024173736572, -0.08954788744449615, 0.4591469466686249, 0.05681870877742767, 0.266928791999...
I am trying to json\_encode an array which is returned from a Zend\_DB query. var\_dump gives: (Manually adding 0 member does not change the picture.) ``` array(3) { [1]=> array(3) { ["comment_id"]=> string(1) "1" ["erasable"]=> string(1) "1" ["comment"]=> string(6) "test 1" } [2]=> ...
[ 0.27417585253715515, 0.3306595981121063, 0.11919063329696655, -0.5796817541122437, -0.019157836213707924, 0.1761023998260498, 0.6973121762275696, -0.7158384919166565, 0.316816508769989, -0.6732733249664307, -0.23746183514595032, 0.3613792657852173, -0.4659149646759033, -0.025517538189888, ...
["comment_id"]=> string(1) "3" ["erasable"]=> string(1) "1" ["comment"]=> string(6) "jhghjg" } } ``` The encoded string looks like: ``` {"1":{"comment_id":"1","erasable":"1","comment":"test 1"}, "2":{"comment_id":"2","erasable":"1","comment":"test 1"}, "3":{"comment_id":"3","erasable":"1","co...
[ 0.021240942180156708, 0.22316542267799377, 0.2482910454273224, -0.08449292182922363, 0.061713166534900665, -0.015160183422267437, 0.23163853585720062, -0.31081774830818176, -0.027756083756685257, -0.7140713930130005, -0.3051016330718994, 0.5303716659545898, -0.3264130651950836, -0.06319960...
(i.e. starting at 0 instead of 1). This is a shot in the dark, however, because I can't see your original code: try setting your array without using keys at all in the first place: ``` array( array(...), array(...), ); ```
[ 0.25535503029823303, 0.12554310262203217, 0.2500988841056824, -0.23807263374328613, 0.2370898574590683, 0.014944295398890972, 0.47555315494537354, -0.42289552092552185, -0.30425626039505005, -0.42624956369400024, 0.0065514263696968555, 0.6850444674491882, -0.21559646725654602, -0.075090557...
Let's say I query for > <http://images.google.com.sg/images?q=sky&imgcolor=black> and I get all the black color sky, how actually does the algorithm behind work? Based on [this paper](http://www.cs.cmu.edu/~har/visapp2006.pdf "Large Scale Image-Based Adult-Content Filtering") published by Google engineers Henry Rowl...
[ 0.3888435661792755, -0.02714185230433941, -0.10656598955392838, 0.1947845220565796, -0.1679307371377945, 0.1275942474603653, 0.07370037585496902, -0.4019661247730255, 0.26281267404556274, -0.4225553274154663, -0.1977073848247528, 0.41929975152015686, -0.21776193380355835, 0.026507396250963...
up using the RGB values in pixels (each color is a 8bit integer value from 0-255 representing how much . of that color is included in the pixel). Methods have also been introduced that rely on properties such as "luminance" (often incorrectly called "luminosity"), which is the density of luminous intensity to the naked...
[ 0.4439568817615509, 0.11096207052469254, 0.7352731823921204, 0.16994722187519073, 0.19512377679347992, 0.20763027667999268, 0.08937496691942215, -0.3732529282569885, -0.6688459515571594, -0.81670081615448, -0.022477606311440468, 0.10672017186880112, -0.13749901950359344, 0.1640218198299408...
which is a rectangle centered in the image and inset by 1/6 of the image dimensions on all sides. Once they've determined the ROI, they have many different algorithms that are then applied to the image including Face-Detection algs, Color Constancy algs, and others, which as a whole find *statistical trends* in the ima...
[ 0.09688574820756912, -0.3623390793800354, 0.7240493297576904, 0.04891951009631157, -0.16499535739421844, 0.3194786608219147, -0.22083432972431183, -0.4964873790740967, -0.19599059224128723, -0.668525218963623, -0.09585118293762207, 0.3058706521987915, -0.23576948046684265, -0.0942116305232...
transform (Kiryati et al., 1991) computed on the edges of the skin color connected components, which allows *them to find straight lines* which are probably not body parts and additionally allows them to better determine which colors are most important in an image, which is a key factor in their Image Color Search. Fo...
[ 0.4707081913948059, -0.4380250871181488, 0.04149559140205383, -0.003209959715604782, -0.14063337445259094, 0.24480919539928436, 0.3315107524394989, -0.6237029433250427, 0.21738670766353607, -0.8639887571334839, 0.13581539690494537, 0.6752609610557556, -0.16029807925224304, -0.0728029906749...
I know the topic of removing www.experts-echange.com has been beaten to death but having to type -site:www.experts-exchange.com is tedious. Even the ability to auto add strings to a query would solve this problem. I can probably wrap this into some wget mess but this seems like basic functionality many users would base...
[ 0.4015387296676636, 0.1438474953174591, 0.23583151400089264, 0.3619517385959625, -0.13733650743961334, -0.11808296293020248, 0.2840689718723297, 0.2847050130367279, -0.156513512134552, -0.5003985166549683, 0.3396361470222473, 0.3561524748802185, -0.03787052258849144, 0.012490231543779373, ...
of words and or operators Google searches process (with good reason I suppose). The [Google Custom Search API](http://code.google.com/apis/customsearch/docs/start.html#sites) allows you to include or **exclude** sites from your search. You can add a custom search engine to your iGoogle home page.
[ 0.42169296741485596, 0.27207547426223755, 0.23144324123859406, 0.24400289356708527, 0.002361491322517395, 0.15455172955989838, 0.5262821912765503, 0.05114220827817917, -0.15509748458862305, -0.4314197599887848, -0.1370907425880432, 0.47997140884399414, -0.25471216440200806, 0.3263524174690...
Baby steps rolling... I have a form with a data grid bound to a table. I have some textboxes on the form bound to the table[columns], so as I scroll the grid, the textboxes show corresponding data. I go to an "Edit Mode" of the textboxes and change the content and hit a save button. The grid doesn't refresh the change...
[ 0.37718385457992554, -0.03301718831062317, 0.536777675151825, 0.14924897253513336, 0.1415671855211258, 0.40830397605895996, -0.02074514888226986, 0.005363760516047478, -0.1429358422756195, -0.45840802788734436, 0.2658923268318176, 0.5888146162033081, -0.03192494809627533, 0.044978465884923...
datagridview. Thanks Have you tried calling the dataGridView's Invalidate method? ``` this.dataGridView1.Invalidate(); ```
[ -0.009589998051524162, 0.18939775228500366, 0.3806295692920685, -0.036959558725357056, -0.19775816798210144, -0.5753391981124878, 0.39775925874710083, 0.127809077501297, -0.33638107776641846, -0.6731802225112915, -0.17400097846984863, 0.5779135823249817, -0.5157696604728699, 0.406996279954...
Is it possible to read/write data from/to a file in a PL/SQL block without using the UTL\_FILE package in Oracle 10g? I currently have a file containing a set of primary keys (approx. 28000) that I need query a table for additional data that needs to be written out to a file. The schema I am using is very restricted a...
[ 0.3506770133972168, 0.3400472402572632, 0.27116841077804565, 0.042330097407102585, 0.13606004416942596, -0.25207284092903137, 0.20696400105953217, -0.37772977352142334, 0.023485295474529266, -0.4709407687187195, -0.02966897003352642, 0.5285652875900269, -0.0014362332876771688, 0.0614624619...
way to work around this problem? Thanks in advance. **[Edit]** I am unable to load the data into a table. Don't have a table to load into or the privileges to create one. I think this is the most difficult part of the problem. How to query the database if the criteria for the query can't conveniently be part of the q...
[ 0.16621772944927216, 0.21913599967956543, 0.18919254839420319, 0.16924796998500824, -0.0004954200121574104, -0.1078592985868454, 0.4334918260574341, -0.018040509894490242, -0.3144461512565613, -0.6576931476593018, 0.20509929955005646, 0.46250787377357483, -0.0891459509730339, 0.08053211122...
directories set up, I would say you are out of luck. You are asking to read and create files on the database server. This is something your DBA should know about. Are you sure you need the files on server? Can you load a file from the client into a table (using the usual client-side tools), and read/write data from th...
[ 0.18214227259159088, 0.030707109719514847, 0.4328702688217163, 0.41509658098220825, 0.15953677892684937, -0.27279171347618103, 0.11877140402793884, 0.022354580461978912, -0.49213293194770813, -0.26773571968078613, -0.2863726019859314, 0.5308586955070496, -0.3141079843044281, 0.197099059820...
the data in sqlplus (using spool), but 28000 seem to be way too large. 28000 is not that much. Loop on the client-side.
[ 0.18384885787963867, -0.34368234872817993, 0.4411015510559082, 0.2694639563560486, -0.16505920886993408, -0.19218593835830688, 0.16927754878997803, -0.006118427030742168, -0.304126113653183, -0.33506909012794495, 0.10437379777431488, 0.15834671258926392, -0.35531187057495117, 0.11085069924...
I am starting an open source cross platform project in C++. My development environment is Linux. There may be other developers who develop from different platforms as well. So I need some help in getting started with the configuration and development environment setup, so that all developers from multiple platforms can...
[ 0.6828258037567139, 0.11179320514202118, -0.1652640700340271, -0.035526443272829056, -0.051263999193906784, -0.18080765008926392, -0.07745759189128876, -0.017057552933692932, -0.12887738645076752, -0.8632347583770752, 0.04213220626115799, 0.32571959495544434, -0.44489240646362305, -0.05915...
this the best practice or do I need to create make files? 3. What are the other settings to be taken care when developing cross-platform applications? Any thoughts? **Edit** Thanks for the answers. One more question. Do you create makefiles by hand? Or is there any tool which can generate it? The most important thi...
[ 0.5840095281600952, -0.03296412155032158, -0.04525413364171982, 0.2751900851726532, -0.42480048537254333, -0.37507790327072144, -0.07439050078392029, 0.013874233700335026, -0.26972389221191406, -0.6293877959251404, -0.0918470099568367, 0.5545580983161926, -0.2854422330856323, -0.2371377497...
other IDE has a problem: Due to their platform, other developers will probably have to generate their own, but won't necessarily have CodeBlocks at hand, or just don't want to use it. There exist several different cross-platform build systems, which are IDE-agnostic. Some of them create Makefiles, others don't use mak...
[ 0.6159536242485046, 0.1843249797821045, 0.0020232959650456905, 0.15048404037952423, -0.19932137429714203, -0.3220156729221344, 0.05317305028438568, -0.07443878799676895, -0.04561091959476471, -0.7311426997184753, -0.05872552841901779, 0.5001126527786255, -0.2773004174232483, -0.10639855265...
(while not a very popular project, it has a large build with a lot of plugins and builds on a lot of platforms including OS X and Windows). While waf is not very broadly adopted, it is meant to be shipped with the source and easy to set-up. My recommendation for you. **Edit:** to get started with your Open Source proj...
[ 0.9594026207923889, 0.2062782347202301, 0.15755516290664673, 0.020032139495015144, -0.18140846490859985, -0.6801300644874573, 0.31359705328941345, -0.004865188151597977, -0.44481372833251953, -0.5435453653335571, -0.03907722607254982, 0.313207745552063, -0.29179647564888, -0.01024623401463...
What's the best way in C++ to copy a pair from a map to vector? I'm doing this so I can subsequently sort the vector. This should do what you want: ``` #include <iostream> #include <vector> #include <map> #include <algorithm> #include <iterator> using namespace std; bool cmp(const pair<int, int> &p1, const pair<int...
[ -0.24792788922786713, -0.33401602506637573, 0.5326420664787292, -0.0933481752872467, 0.0666457861661911, 0.278288334608078, -0.07403477281332016, -0.4774457514286041, -0.19511304795742035, -0.7302982807159424, -0.022324860095977783, 0.278518408536911, -0.6658628582954407, -0.28439271450042...
v.end(), cmp); for(int i = 0; i < v.size(); ++i) cout << v[i].first << " : " << v[i].second << endl; return 0; } ```
[ 0.1376110464334488, -0.09595688432455063, 1.0669026374816895, -0.4301581382751465, 0.1135091707110405, 0.33188214898109436, 0.23291802406311035, -0.5470262765884399, -0.28162118792533875, -0.5087957978248596, -0.511310875415802, 0.41975122690200806, -0.31332284212112427, 0.4488797485828399...
Need help with a silly question. How do I get PartCover.Browser.exe to load and show an existing coverage xml generated by PartCover.exe? I have a batch file that runs PartCover.exe and my tests and generates the coverage xml without problems. Then I try to load the xml with PartCover.Browser.exe. ``` "C:\Program Fil...
[ 0.13548533618450165, 0.24976548552513123, 0.5965710878372192, -0.07356233149766922, -0.14951491355895996, 0.06235117465257645, 0.1354580819606781, -0.4107692539691925, -0.10431423783302307, -0.8810984492301941, -0.09947096556425095, 0.47882285714149475, -0.4515227675437927, -0.184836626052...
return p1.second < p2.second; } int main() { map<int, int> m; for(int i = 0; i < 10; ++i) m[i] = i * -i; vector<pair<int, int> > v; copy(m.begin(), m.end(), back_inserter(v)); sort(v.begin(), v.end(), cmp); for(int i = 0; i < v.size(); ++i) cout << v[i].first << " : " << v[i]...
[ -0.2512328624725342, -0.3245902359485626, 0.819804847240448, -0.40184637904167175, 0.21974819898605347, 0.4577293395996094, 0.09065806120634079, -0.5423823595046997, -0.4270913600921631, -0.6686317920684814, -0.5801922678947449, 0.3594374656677246, -0.4102321267127991, 0.18734191358089447,...
I am considering helping an open-source gaming project with creating their setup file. The game is currently weights around 300 MB and is packaged in a zip file, playable straight after it's unarchived. The zip file contains separate executables for Windows, Mac, and Linux as well as compressed data files that are used...
[ 0.20065751671791077, 0.09031586349010468, 0.3690560460090637, 0.30576589703559875, 0.29810088872909546, -0.1005866676568985, -0.2988682985305786, -0.028692740947008133, -0.24888946115970612, -0.6001827716827393, -0.09905295819044113, 0.36756935715675354, 0.1214589849114418, -0.010660048574...
GPLv2) and its own maturity. So, the question boils down to: * What is a good install creation tool for **Windows**? (creating .exe, .msi) * What is a good install creation tool for **OS X**? (creating .dmg, ...) * What is a good install creation tool for **Linux**? (creating .rpm, .deb, .bin, ...) Please post your ...
[ 0.3279493451118469, 0.14119906723499298, 0.19516251981258392, -0.19698315858840942, -0.20789997279644012, -0.4585631191730499, 0.01662919484078884, -0.03126101568341255, -0.10665655136108398, -0.8317330479621887, 0.2039414346218109, 1.0943807363510132, -0.18955133855342865, -0.078739985823...
have, and from there, it was quite easy to add installation types, extra pages (license, etc), and other "features".
[ 0.48605695366859436, 0.11402210593223572, 0.32684963941574097, 0.04046045243740082, -0.1454649567604065, -0.4499560594558716, -0.03846939280629158, -0.02430800534784794, -0.11268683522939682, -0.32223519682884216, -0.40930241346359253, 0.34542936086654663, -0.168109729886055, 0.21411761641...
We have thousands of DOS programs that were all written in the 80s using 16-bit C, comprising over 1,000,000 lines of code. Many of these programs utilize libraries that directly access the screen, drive, etc. (and we don't have the sources for these libraries). Whenever we try to run them in Win2000 or above, even in ...
[ 0.6128290891647339, 0.45559927821159363, 0.1820933222770691, 0.4437161386013031, 0.352563738822937, -0.26985281705856323, 0.1248490959405899, -0.05006508156657219, 0.029110636562108994, -0.5153295397758484, 0.08930995315313339, 0.5002591013908386, -0.1068226620554924, 0.3131504952907562, ...
20 or so copies). Our company is extremely careful about licensing, so they have no interest in buying the OEM copies (since we are not a system builder). Our new 32-bit software won't be ready for 3 years, so unless someone knows where we can buy lots of Win98 retail boxes, I'm stuck trying to figure out how to get 1...
[ 0.6936526894569397, 0.2812598645687103, 0.47816044092178345, 0.34972456097602844, 0.24004876613616943, 0.02891951985657215, -0.2223615050315857, -0.03148201107978821, -0.31347233057022095, -0.2020818293094635, 0.06890245527029037, 0.7124201655387878, 0.13841959834098816, 0.0954753458499908...
There are several tabs in GUI runner of NUnit: [![alt text](https://i.stack.imgur.com/InUvN.png)](https://i.stack.imgur.com/InUvN.png) I understand that using Console.WriteLine (...) shows the messages in "Console.Out" tab. My question is what other tabs are for and how can I log messages to them? [EDIT] I apologise...
[ -0.2301938682794571, -0.10354919731616974, 0.597664475440979, 0.15890753269195557, -0.4940524697303772, 0.013485767878592014, 0.6977556347846985, -0.14427316188812256, -0.12994621694087982, -0.5326870083808899, -0.04753592610359192, 0.6441613435745239, 0.019185131415724754, -0.108191162347...
AM Checking operation 1....OK Checking value of variable "X": 52.56....OK End Time: 2009-03-26 11:15:19 AM Time taken to execute test: 0.00:00:06.000 ==== TEST2 starts ==== . . ``` Any suggestion how can I achieve this? Settings for the tabs are in the NUnit options - see the [docs here](http://www.nunit.org/index.p...
[ 0.08991680294275284, 0.25640106201171875, 0.6488425135612488, -0.11041393876075745, 0.00871188659220934, -0.10053464770317078, 0.9232538938522339, -0.4615633487701416, 0.1304946392774582, -0.5394914150238037, -0.0051401592791080475, 0.884940505027771, 0.1208733469247818, -0.196182087063789...
I wish to extend a base class in C# with some additional functionality. I have existing code which returns an array of the base class objects (Account) which I need to convert into the extended version. So I have the extended version: ``` class AccountXtra : Account { public int Period { get; set; } public in...
[ 0.17668002843856812, 0.17502711713314056, 0.5389666557312012, -0.3699270188808441, 0.01154314074665308, -0.06482512503862381, 0.3422548174858093, -0.14967669546604156, -0.4227772653102875, -0.6381068229675293, -0.0739440843462944, 0.6312285661697388, -0.20499244332313538, 0.060832668095827...
doesn't work AccountXtra newInstance = new AccountXtra(); newInstance = accountInstance; ``` You need to be generating new objects of the *derived* class now, not the base. Replace your old calls to `new Account` with `new AccountXtra`. Or, you need a constructor for `AccountXtra` that takes an `Account` object and ma...
[ 0.32946011424064636, 0.18603172898292542, 0.451905757188797, -0.1977124810218811, 0.2673237919807434, 0.002921401523053646, 0.44625988602638245, -0.22575797140598297, -0.1370408684015274, -0.41077569127082825, -0.08545288443565369, 0.6684908270835876, -0.2846801280975342, 0.057713743299245...
xtraCastBack = (AccountXtra)xtraCastAsBase; ``` But this will not: ``` Account Base = new Account(); AccountXtra baseAsDerived = (AccountXtra)Base; //Cast base to derived class ```
[ 0.1143537312746048, 0.17659081518650055, 0.3391357660293579, -0.24005888402462006, -0.03242678567767143, 0.060807790607213974, 0.30629709362983704, -0.18897609412670135, -0.046404823660850525, -0.34310171008110046, -0.016245704144239426, 0.5446307063102722, -0.1652933657169342, 0.054788898...
Can anyone show me the step of restore and recovery of below scenario? I have used the differential backup (cumulative) everyday. ``` RUN { RECOVER COPY OF DATABASE WITH TAG "whole_database_copy"; BACKUP INCREMENTAL LEVEL 1 CUMULATIVE FOR RECOVER OF COPY WITH TAG "whole_database_copy" DATABASE; } ``` I have co...
[ 0.2605890929698944, 0.5335054993629456, 0.3063277304172516, 0.14377431571483612, 0.08083928376436234, -0.0982314720749855, 0.49167874455451965, -0.099692702293396, -0.5026621222496033, -0.5960418581962585, -0.08200405538082123, 0.9022194743156433, -0.03756108507514, 0.16870658099651337, ...
with listening to what people on forums have to say, now is not the time to experiment.
[ 0.5130763053894043, 0.03673243895173073, 0.04985702037811279, 0.16076883673667908, -0.0299850981682539, -0.39779984951019287, 0.25437337160110474, 0.0682145282626152, 0.01088108029216528, -0.4978962242603302, 0.40242376923561096, 0.3391116261482239, 0.40479153394699097, 0.1275339275598526,...
i've been making an asp website in which i'm providing the user a facility to upload videos and view them once they are uploaded. I've been successfully been able to upload videos to my server, but not getting as how to play it on the client's page. I want to buffer the video and stream it on user's browser, don't want...
[ 0.7059985399246216, -0.09256349503993988, 0.49523216485977173, -0.10654915124177933, -0.09419713169336319, 0.059391655027866364, 0.07847703248262405, -0.02069767750799656, -0.5164099335670471, -0.5125421285629272, -0.08737735450267792, 0.7869722247123718, -0.12915876507759094, 0.1957455128...
I recently encountered this problem. I found many instances of people asking the question—[here, for example](http://www.codeguru.com/forum/showthread.php?p=982326)—but no concrete answers. Here's the sample code hoisted from that link: ``` class AFX_BASE_APPLICATION_APP_CLASS CFileExtension { public: CFileExtens...
[ 0.15219473838806152, 0.3219805061817169, 0.6437026262283325, -0.04235558584332466, 0.16443967819213867, 0.35084056854248047, 0.20915496349334717, -0.23540817201137543, -0.09915462881326675, -0.39718395471572876, 0.011985701508820057, 0.5570331811904907, -0.48432835936546326, 0.062704242765...
returned `class AFX_BASE_APPLICATION_APP_CLASS`. And, since it thinks it's a function, it also thinks it needs parentheses. You just need to find where `AFX_BASE_APPLICATION_APP_CLASS` is defined and `#include` that file.
[ -0.00907738134264946, 0.12024298310279846, 0.21636684238910675, -0.25841155648231506, 0.20830096304416656, 0.17051376402378082, -0.02357599139213562, -0.17715464532375336, -0.12472494691610336, -0.24013566970825195, -0.2625921070575714, 0.4494958519935608, -0.43989285826683044, -0.29267129...
I am creating what I expect to be ruby gem. Anyone have a good link to a tutorial on converting a simple library or plugin to a gem? Also, *especially*, what is the process that Ruby uses to allow the require to find gems? It seems to be something more than putting the files in the gem path (or is my configuration scre...
[ 0.9533109068870544, 0.21740496158599854, -0.14310209453105927, 0.13453519344329834, -0.2952395975589752, -0.4186965525150299, 0.20499087870121002, -0.14946401119232178, -0.09456492215394974, -0.5882554054260254, 0.1994766741991043, 0.8744783401489258, -0.1744232028722763, 0.107394292950630...
make a file `whatever.gemspec`, and put the following in there, filling in the appropriate values: ``` Gem::Specification.new do |spec| spec.name = 'the-name-of-your-gem' spec.version ='0.0.1' # this is important - it specifies which files to include in the gem. spec.files = ["lib/whatever.rb"] #...
[ 0.9890483021736145, 0.26747891306877136, 0.3400387167930603, -0.0861048698425293, 0.02231273613870144, -0.4962191581726074, 0.03555511310696602, -0.3693588674068451, -0.1581982970237732, -0.019743939861655235, -0.04836273565888405, 0.9304686188697815, 0.12723587453365326, 0.076395317912101...
spec.has_rdoc = true # if you have a ruby forge project spec.rubyforge_project = 'your-project-name-on-rubyforge' # if you have any dependencies on other gems, list them thusly spec.add_dependency('hpricot') spec.add_dependency('log4r', '>= 1.0.5') end ``` 3. now, to build the gem, use the `gem b...
[ 0.7708268761634827, 0.2318134307861328, 0.22984901070594788, -0.0980425477027893, -0.21511143445968628, -0.3713420331478119, 0.5624284148216248, -0.515278160572052, -0.05610436946153641, -0.521248996257782, -0.2882859408855438, 0.839094340801239, -0.09316276758909225, -0.055398501455783844...
library ``` For more on what the various settings in the `gemspec` file, check the [GemSpec Reference](http://rubygems.org/read/chapter/20). Personally, I use rubygems a lot to package executable scripts as well, and find it very handy for that.
[ 0.5033873915672302, 0.41150304675102234, -0.20053641498088837, 0.2710142731666565, -0.22337941825389862, -0.34694692492485046, 0.2518868148326874, 0.14920933544635773, -0.37934160232543945, -0.5214452743530273, -0.07244417816400528, 0.5777122974395752, 0.29593968391418457, 0.12013122439384...
Are there any C# attributes that I can apply to class members, to change the way they appear in the IntelliSense listings? This popped into my head when I was building a class with many static constants, and I (briefly!) wanted it to look like an enumeration in IntelliSense. Yes, that's silly. But it got me thinking ...
[ 0.09757321327924728, 0.13885629177093506, 0.11521844565868378, 0.11174970865249634, -0.12598903477191925, -0.07615271955728531, -0.0024292997550219297, 0.12790115177631378, -0.30057722330093384, -0.3100576400756836, -0.05803732946515083, 0.5618194937705994, -0.31368640065193176, 0.40281039...
DebuggerDisplay attribute described [here](https://stackoverflow.com/questions/471241/can-i-customize-the-intellisense-value-shown-when-hovering-while-debugging-in-vis).
[ -0.33587804436683655, -0.4547589123249054, 0.46767565608024597, 0.16686780750751495, -0.03567647561430931, -0.22873637080192566, 0.2138359248638153, -0.0853242501616478, -0.16454541683197021, -0.5343173742294312, -0.19487033784389496, 0.39110425114631653, -0.08249925076961517, 0.0147574935...
I want to find the distance using wi-fi and plot the marker on map in iPhone. So any idea or code i can get for that? Upon first reading your question, i was under the assumption you were referring to distance to an access point. After writing a bunch about that, i realized you might mean something else. In case that ...
[ 0.7490342259407043, -0.036147113889455795, 0.5064646005630493, 0.3063783645629883, -0.029352465644478798, -0.048616159707307816, -0.0017219255678355694, -0.07998422533273697, -0.391502320766449, -0.5142912864685059, 0.0825466513633728, 0.334109902381897, -0.2800731956958771, -0.02037265710...
on the receiver * 802.11 b/g protocol This cannot be done. Even if you were working at the [PHY](http://en.wikipedia.org/wiki/OSI_model) level, this is an impossible problem to solve. To make it slightly more feasible, you need to [triangulate](http://en.wikipedia.org/wiki/Triangulation) the position of your receiver ...
[ 0.37498241662979126, -0.20338711142539978, 0.5958703756332397, -0.14263403415679932, -0.1748187094926834, -0.3900220990180969, 0.5395787358283997, -0.4657278060913086, -0.38435688614845276, -0.680963397026062, -0.30248233675956726, 0.6200972199440002, -0.22704817354679108, -0.1835313886404...
RF hardware, which obviously you're not about to do for the iPhone. Your best bet to track down the location of a base station is to record the WiFi signal strength as you change the position of the phone. By 'change the position', you would essentially have to sweep around the area. With some good heuristics, and rob...
[ 0.1741732954978943, -0.03478775918483734, 0.6356717348098755, 0.036907706409692764, 0.21801677346229553, -0.3297266662120819, 0.28857335448265076, -0.6730549931526184, -0.07785528898239136, -0.5979164242744446, -0.03848006948828697, 0.8239620923995972, 0.02433866821229458, -0.4698759317398...
How do I match the following string? ``` http://localhost:8080/MenuTest/index.action ``` The regex should return true if it contains "MenuTest" in the above pattern. Cheers Maybe you don't need a regex? ``` String url = "http://localhost:8080/MenuTest/index.action"; boolean hasWhatImLookingFor = url.contains("...
[ 0.19205185770988464, 0.4333221912384033, 0.6712967157363892, -0.24413952231407166, -0.14204971492290497, -0.04835433140397072, 0.4532090127468109, -0.3670105040073395, -0.0003772059571929276, -0.4211794435977936, -0.07396086305379868, 0.7473258972167969, 0.011018708348274231, -0.0633152946...
Does anyone know the database format for ACT. I am trying to write an exporter for ACT! I've looked for libraries and can't find any obvious ones that will help me interact with the CRM system. i have not programmed with act since act 2000 (i did the programming in 2004, though). i used their ACTOLE.APPOBJECT com objec...
[ -0.07170788198709488, -0.16936656832695007, 0.1156158521771431, 0.0369521863758564, -0.04323190450668335, -0.01821376383304596, 0.3313434422016144, 0.13434168696403503, -0.4709724485874176, -0.5234594941139221, 0.10268060117959976, 0.3978164494037628, -0.4634527862071991, -0.22726424038410...
Recently I've faced such problem. I'm working on the application, in which logging is very important. By logs in that application I mean the messages, like * User A(id=x) has created invoice(invoice # is XXX) (1) * User B(id=y) has purchased the book (2) * User A(id=x) has approved invoice XXX (3) (1) and (3) are m...
[ 0.41926345229148865, 0.34468144178390503, 0.6583355069160461, -0.011264028958976269, -0.021252313628792763, -0.04223627597093582, 0.08238633722066879, -0.25968798995018005, -0.3227088153362274, -0.6090906262397766, 0.03200004622340202, 0.292609840631485, -0.11694295704364777, 0.10533049702...
problem like this: I've created at the beginning of the request some unique [UUID](http://en.wikipedia.org/wiki/UUID) code, and prepend any log messages with this unique code. So, I can find all the messages of particular thread by simple grep UNIX command. That solves the problem, but I'm not sure it is the best sol...
[ 0.24865522980690002, -0.12772302329540253, 0.1277998387813568, 0.357955664396286, -0.1156618520617485, -0.16871915757656097, 0.11861616373062134, 0.13606414198875427, -0.38737037777900696, -0.4824499785900116, 0.2833842635154724, 0.42577943205833435, -0.12600509822368622, 0.303007453680038...
output log of everything in case it's the sequence of events that matters as opposed to the classification. 2. Use a logging package if you don't already have one, examples are [The Log Package](http://www.indelible.org/php/Log/guide.html), or [Zend\_Log](http://framework.zend.com/manual/en/zend.log.html) where you can...
[ 0.4718836545944214, -0.41526269912719727, -0.19935475289821625, 0.17655426263809204, -0.2124912291765213, -0.4186345040798187, 0.13552427291870117, -0.0702170729637146, -0.30039462447166443, -0.5305904746055603, 0.005362271796911955, 0.43721625208854675, -0.3151436448097229, -0.16688205301...
I'm trying to port a GTK-based Linux app to Mac OS-X. I have the GUI working OK but now I need to create a Widget which embeds MPlayer. I should be able to use the -wid option of MPlayer to embed it in my app but I need to find the Window ID. Does anyone know how to find the window ID of a GTK Widget or Container on O...
[ 0.3166818618774414, 0.16653425991535187, 0.17101137340068817, 0.30537283420562744, -0.25297144055366516, -0.07216531783342361, 0.260082483291626, 0.23479245603084564, -0.24922597408294678, -0.7646585702896118, 0.1639755517244339, 0.8020328283309937, -0.3809790015220642, 0.11246439814567566...
to do, MPlayer wants a X11 window ID, and you're not using X11 at all.
[ 0.4788757860660553, 0.012459252029657364, 0.16499055922031403, 0.2869277596473694, -0.12552301585674286, -0.32948067784309387, 0.19471564888954163, 0.1299167275428772, -0.386740505695343, -0.5472860932350159, 0.07058144360780716, 0.3902676999568939, -0.1849960833787918, 0.14379598200321198...
I have a structure like this: ``` <Info ID="1"> ... <Date>2009-04-21</Date> </Info> <Info ID="2"> ... <Date>2009-04-22</Date> </Info> <Info ID="3"> ... <Date>2009-04-20</Date> </Info> ``` I want to get the latest date using XSLT (in this example - 2009-04-22). Figured it out, wasn...
[ -0.05405565723776817, 0.1391483098268509, 0.8849859237670898, -0.09523975104093552, -0.1524200588464737, -0.4005642235279083, 0.3141826093196869, -0.06238093599677086, -0.15817290544509888, -0.6336938738822937, -0.02350512519478798, 0.5526826977729797, 0.03701210394501686, 0.27030879259109...
<xsl:sort select="Date" order="descending" /> <xsl:if test="position() = 1"> <xsl:value-of select="Date"/> </xsl:if> </xsl:for-each> </xsl:variable> <xsl:value-of select="$latest"/> ```
[ -0.24794413149356842, -0.36165910959243774, 0.6458826065063477, -0.07968370616436005, 0.10177972167730331, -0.18836010992527008, -0.22259296476840973, -0.3246164619922638, 0.06883466243743896, -0.46908387541770935, -0.46137920022010803, 0.20783750712871552, 0.11070040613412857, 0.045431829...
I'm having some problems with the following: * I want to get the first visible AND frozen column of a column collection. I think this will do it: ``` DataGridViewColumnCollection dgv = myDataGridView.Columns; dgv.GetFirstColumn( DataGridViewElementStates.Visible | DataGridViewElementStates.Frozen); ``` * Is i...
[ 0.10340593010187149, -0.21776293218135834, 0.5706336498260498, -0.04402703046798706, -0.11957591027021408, -0.0009561348706483841, 0.3391362726688385, 0.08353251963853836, -0.2945345938205719, -0.5450127124786377, -0.2349328100681305, 0.20311623811721802, -0.44188451766967773, 0.1430605053...
GetFirstColumnWithAny( DataGridViewColumnCollection columns, // optional "this" DataGridViewElementStates states) { foreach (DataGridViewColumn column in columns) { if ((column.State & states) != 0) return column; } return null; } ``` Or with LINQ: ...
[ -0.02533891424536705, -0.08678649365901947, 0.852521538734436, -0.10959316045045853, 0.29988762736320496, -0.03224531188607216, 0.44656312465667725, -0.42630013823509216, -0.15471093356609344, -0.5409867763519287, -0.40029945969581604, 0.592194676399231, -0.25030753016471863, 0.06579362601...
.FirstOrDefault(col => (col.State & states) != 0); ```
[ -0.009216828271746635, -0.11585301905870438, 0.22146102786064148, -0.01973891258239746, 0.20737262070178986, -0.23551775515079498, 0.35552629828453064, -0.2007274329662323, -0.22405914962291718, -0.8796797394752502, -0.3338557779788971, 0.4201560318470001, -0.449344664812088, 0.18154281377...
If not, maybe you could tell me why. I get NotSerializableException when my class is being serialized. Inside the class I am passing this anonymous class to a method: ``` new org.apache.commons.collections.Closure() { ... }; ``` **The question is still unanswered. I want to know if there is a standard Closure i...
[ 0.16193526983261108, -0.03208966925740242, 0.2403770238161087, 0.21642933785915375, -0.17555058002471924, -0.3047052323818207, 0.2824605703353882, 0.5066452622413635, -0.2751193642616272, -0.669780969619751, -0.020226595923304558, 0.35333555936813354, -0.3478938043117523, 0.459873676300048...
I'm looking for a way to programatically generate a twitter feed for a .NET application. Any recommendations as to a good wrapper for the twitter api to ease the work? Boaz [TweetSharp](https://www.nuget.org/packages/TweetSharp/) looks like it should be a decent option as well.
[ 0.7638776898384094, -0.1695820689201355, -0.26377445459365845, 0.22822324931621552, -0.11412917822599411, -0.2809572219848633, 0.01230571512132883, 0.5254431366920471, -0.23083092272281647, -0.5112485289573669, 0.31575292348861694, 0.2214435338973999, -0.06154399737715721, 0.08886046707630...
This is an interview question. > You need to design a stack which holds an integer value such that `getMinimum()` function should return the minimum element in the stack. > > > For example: > > > > > case #1 > > > > > > 5 ← TOP > > > > 1 > > > > 4 > > > > 6 > > > > 2 > > > > > > When getMinimum() ...
[ -0.09367796778678894, -0.20810139179229736, 0.2343527376651764, 0.07989619672298431, -0.12825213372707367, -0.12000399082899094, 0.007862509228289127, -0.45896992087364197, -0.173025444149971, -0.4541035294532776, -0.08192314207553864, 0.4122818410396576, -0.3073117733001709, 0.05329655110...
> > > `stack.pop()` > > > > `stack.pop()` > > > > > > Note: Both 5 and 1 are popped out of the stack. > > So after this, the stack looks like > > > > > > 4 ← TOP > > > > 6 > > > > 2 > > > > > > When `getMinimum()` is called it should return 2 which is the minimum in the stack. > > > **Constraints:** >...
[ -0.26814451813697815, -0.31499212980270386, 0.4755799174308777, -0.08661254495382309, 0.17072460055351257, -0.10028454661369324, 0.1276368796825409, -0.5165161490440369, -0.4246211349964142, -0.8544782400131226, -0.2709360718727112, 0.507928729057312, -0.16985000669956207, -0.0238095745444...
if you use extra space, it should be of constant space. EDIT: This fails the "constant space" constraint - it basically doubles the space required. I very much doubt that there's a solution which *doesn't* do that though, without wrecking the runtime complexity somewhere (e.g. making push/pop O(n)). Note that this does...
[ 0.24643699824810028, -0.02214389480650425, 0.25469034910202026, 0.06843874603509903, 0.19695787131786346, 0.19985029101371765, 0.20580442249774933, -0.037280235439538956, -0.7166520357131958, -0.6776787638664246, -0.19772326946258545, 0.62685227394104, -0.2940598428249359, -0.1210566684603...
min stack too. When you push the main stack, push either the new element or the current min, whichever is lower. `getMinimum()` is then implemented as just `minStack.peek()`. So using your example, we'd have: ``` Real stack Min stack 5 --> TOP 1 1 1 4 2 6
[ -0.34674713015556335, -0.4387294352054596, 0.5855499505996704, -0.08257944881916046, 0.06060193479061127, 0.17234133183956146, -0.019864432513713837, 0.09684527665376663, -0.1176205575466156, -0.6719155311584473, -0.32158586382865906, 0.7611032128334045, 0.08637527376413345, -0.06912539899...
2 2 2 ``` After popping twice you get: ``` Real stack Min stack 4 2 6 2 2 2 ``` Please let me know if this isn't enough information. It's simple when you grok
[ 0.13388340175151825, 0.3369525074958801, 0.4138997495174408, -0.22498273849487305, -0.05204981192946434, 0.03912290185689926, 0.03092900477349758, -0.15565794706344604, -0.48806139826774597, -0.4815141558647156, -0.16297197341918945, 0.8452767133712769, -0.05926373973488808, -0.01228586956...
it, but it might take a bit of head-scratching at first :) (The downside of course is that it doubles the space requirement. Execution time doesn't suffer significantly though - i.e. it's still the same complexity.) EDIT: There's a variation which is slightly more fiddly, but has better space in general. We still hav...
[ 0.1435142159461975, -0.298088937997818, 0.5886573195457458, 0.18912246823310852, 0.06889326125383377, 0.1477828174829483, 0.037076663225889206, 0.02615298330783844, -0.28944507241249084, -0.2874586582183838, -0.27175360918045044, 0.6357353329658508, 0.11741903424263, -0.08259785920381546, ...
to the current min value. This allows duplicate min values. `getMinimum()` is still just a peek operation. For example, taking the original version and pushing 1 again, we'd get: ``` Real stack Min stack 1 --> TOP 1 5 1 1 2 4
[ -0.2425510585308075, -0.3553890883922577, 0.5729619264602661, -0.06685473769903183, 0.18193496763706207, 0.16491134464740753, 0.16364456713199615, -0.14666146039962769, -0.25780248641967773, -0.4963892698287964, -0.2969641387462616, 0.6421269178390503, -0.03198811411857605, 0.0813122391700...
6 2 ``` Popping from the above pops from both stacks because 1 == 1, leaving: ``` Real stack Min stack 5 --> TOP 1 1 2 4
[ -0.27678075432777405, 0.16889506578445435, 0.6113646030426025, -0.08942842483520508, -0.06389553844928741, 0.001464308239519596, 0.15208756923675537, -0.27984172105789185, -0.18401215970516205, -0.2480984628200531, -0.455589234828949, 0.5268341898918152, 0.11281810700893402, 0.179959952831...
6 2 ``` Popping again *only* pops from the main stack, because 5 > 1: ``` Real stack Min stack 1 1 4 2 6
[ -0.13337105512619019, 0.12406577169895172, 0.6113740801811218, -0.1488753855228424, -0.03139588236808777, 0.011224514804780483, 0.139351949095726, -0.04267699643969536, -0.20209304988384247, -0.41437026858329773, -0.48492535948753357, 0.46578797698020935, 0.04354073479771614, 0.21345520019...
2 ``` Popping again pops both stacks because 1 == 1: ``` Real stack Min stack 4 2 6 2 ``` This ends up with the same worst
[ -0.4572201669216156, 0.19026166200637817, 0.3558819591999054, -0.1937875598669052, -0.1340978592634201, 0.03187735378742218, 0.4870956540107727, -0.14082513749599457, -0.2385995239019394, -0.7175642251968384, -0.11265257000923157, 0.5986244082450867, -0.024417757987976074, 0.14906096458435...
case space complexity (double the original stack) but much better space usage if we rarely get a "new minimum or equal". EDIT: Here's an implementation of Pete's evil scheme. I haven't tested it thoroughly, but I *think* it's okay :) ``` using System.Collections.Generic; public class FastMinStack<T> { private re...
[ -0.3182712495326996, -0.3569476008415222, 0.42700493335723877, 0.14167550206184387, 0.3322299122810364, 0.12149209529161453, -0.03769140690565109, -0.03872371464967728, -0.34499815106391907, -0.7420222759246826, -0.08430059254169464, 0.7002409100532532, -0.3477902412414551, 0.2048229575157...
} public void Push(T element) { if (stack.Count == 0 || comparer.Compare(element, currentMin) <= 0) { stack.Push(currentMin); stack.Push(element); currentMin = element; }
[ -0.12313385307788849, -0.5491240620613098, 0.5975630283355713, -0.41657549142837524, 0.1432914435863495, 0.13609763979911804, 0.20650245249271393, -0.42721086740493774, -0.13204379379749298, -0.30645155906677246, -0.2657046616077423, 0.4128619432449341, -0.4722360670566559, 0.2921866774559...
else { stack.Push(element); } } public T Pop() { T ret = stack.Pop(); if (comparer.Compare(ret, currentMin) == 0) { currentMin = stack.Pop(); }
[ -0.03695479407906532, -0.5028944611549377, 0.6625887155532837, -0.18469645082950592, 0.1851169317960739, 0.22639308869838715, 0.31240198016166687, -0.313852459192276, -0.22937747836112976, -0.13523440062999725, -0.48151150345802307, 0.6784583926200867, -0.36788031458854675, 0.1061069220304...
return ret; } } ```
[ -0.20811742544174194, 0.15497253835201263, 0.10825169831514359, -0.4879724979400635, 0.13468162715435028, -0.015139126218855381, 0.3738924562931061, 0.17880947887897491, 0.19163145124912262, -0.34984877705574036, -0.6327241659164429, 1.0051442384719849, -0.2991126775741577, 0.2629148066043...
I would like to show the user a splash screen (a picture) while my Cocoa-based application launches. How would this be possible? --- First thanks a lot. because my app running for a while time , so I want to show a splash before app running . Now if I show a window inside with a image , after that how to run the app?...
[ 0.5464346408843994, 0.03917054086923599, 0.6536306142807007, 0.2501436471939087, -0.24570949375629425, -0.058518946170806885, 0.15204687416553497, -0.00890345685184002, -0.3003884255886078, -0.6235272884368896, 0.06276508420705795, 0.6360576152801514, -0.030195146799087524, -0.149769291281...
in applicationDidFinishLaunching: use orderOut,Now I found that the mainWindow not to show and the app terminate ,why ? How to do to resolute this question? Thanks! Although Peter's answer is ultimately correct (you *should* rewrite your app to launch faster), sometimes that's not a practical option. For example loadin...
[ 0.2115238755941391, -0.0924220159649849, 0.47963646054267883, 0.01908593438565731, -0.028907660394906998, -0.15320362150669098, 0.47678616642951965, -0.1468743532896042, -0.44615018367767334, -0.5443112850189209, -0.5328952670097351, 0.4750339388847351, -0.3431715965270996, 0.0303263254463...
MainMenu.nib and add an outlet to your app delegate referencing that window. You can then put the window onscreen in `applicationWillFinishLaunching:` and hide it in `applicationDidFinishLaunching:`. Note that the main thread's NSRunLoop is not iterating during this time, so if you want to update the splash screen (wit...
[ 0.026266396045684814, -0.2682676613330841, 0.5712481737136841, 0.13497069478034973, 0.16813026368618011, -0.10691987723112106, 0.4727634787559509, 0.23475220799446106, -0.3580116927623749, -0.8636006712913513, -0.23524287343025208, 0.6488548517227173, -0.2959468960762024, 0.113640382885932...
I have 2 Oracle questions 1. How do I translate this SQL Server statement to work on Oracle? ``` Create table MyCount(Line int identity(1,1)) ``` 2. What is the equivalent of SQL Servers Image type for storing pictures in an Orace database? You don't need to use triggers for this if you manage the inserts: ``` CRE...
[ 0.4640696942806244, 0.09543449431657791, 0.40795257687568665, 0.2861054539680481, 0.0024632553104311228, 0.21371538937091827, -0.10962387174367905, -0.31123384833335876, -0.07038983702659607, -0.5639010667800903, 0.05370037257671356, 0.28712373971939087, -0.4718485474586487, -0.12138476967...
Sequence reference](http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/statements_6014.htm#i2154127). * [Create table reference](http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/statements_7002.htm#i2095331). * [Oracle® Database Application Developer's Guide - Large Objects](http://download.or...
[ -0.1482297033071518, 0.2854120433330536, 0.24972428381443024, -0.05143243074417114, 0.10569119453430176, 0.22484569251537323, -0.17561599612236023, -0.19448889791965485, -0.2226610779762268, -0.4196584224700928, -0.34810179471969604, 0.16806432604789734, -0.45969241857528687, 0.26891857385...
Is there a way in MS-Access to delete the data in all the tables at once. We run a database in access, save the data every month and then delete all the data in access. But it requires deleting data from a lot of tables. Isn't there a simpler/easier way to do so? Why don't you keep an empty copy of the database on hand...
[ -0.009219607338309288, 0.21122698485851288, 0.3467804789543152, 0.44325053691864014, 0.3293803036212921, 0.04895669221878052, -0.04276561364531517, 0.34046289324760437, -0.6030700206756592, -0.5864475965499878, 0.025654496625065804, 0.2793430685997009, -0.22214184701442719, 0.3363141715526...
Do you know a site that offers a tutorial with sample source code for a 3-tier application (the usual data access layer, business layer and UI layer)? The simple, readable and intuitive the source code. Best practices that are applied to the code are welcome as well. Take a look at [Appfuse](http://appfuse.org) , it's...
[ 0.6113497018814087, -0.16405098140239716, 0.018261507153511047, 0.12475357949733734, 0.09909124672412872, 0.045495159924030304, 0.30997759103775024, -0.23348940908908844, -0.08702541142702103, -0.4555271565914154, 0.046582698822021484, 0.3499203026294708, -0.06877472996711731, -0.308500826...