Search Results

Search found 8167 results on 327 pages for 'general tapioca'.

Page 195/327 | < Previous Page | 191 192 193 194 195 196 197 198 199 200 201 202  | Next Page >

  • turning open source software into a consulting business ?

    - by sofreakinghigh
    just some general and specific questions about running a business which uses open source software and sells training, services, and other value added solutions utilizing the open source asset(s). 1) how much modification do you need to make to an existing open source software/framework to give a new brand ? open source (GPLv3) branding issues here.... for ex) Mambo and Joomla, i think they are pretty much same ? but they have different labels. 2) Is there a disadvantage of promoting open source software/framework/suite in hopes of selling value added services and solutions on top of the Open source asset ? 3) can Open source assets be marketing point for lowered Total Ownership Cost and transparency ? meaning, clients will not be using some mysterious, opaque proprietary asset ? 4) is competition fierce? cost of developing software is non existing because you are using an open source asset. barrier to entry is minimal ??

    Read the article

  • Is it safe to catch an access violation in this scenario?

    - by Eloff
    I've read a lot, including here on SO that suggests this is a very bad idea in general and that the only thing you can do safely is exit the program. I'm not sure that this is true. This is for a pooling memory allocator that hands off large allocations to malloc. During pool_free() a pointer needs to be checked it it belongs to a pool or was allocated with malloc. By rounding the address down to the nearest 1MB boundary, I get a pointer to the beginning of a block of memory in the pool, or undefined if malloc was used. In the first case I can easily verify that the block of memory belongs to the pool, but, if it does not I will either fail this verification, or I will get an access violation (note that this is a read-only process). Could I not catch this with SEH (Windows) or handle the signal (POSIX) and simply treat it as a failed verification? (i.e. this is only possible if malloc was used, so pass the ptr to free())

    Read the article

  • In MS SQL Server, is there a way to "atomically" increment a column being used as a counter?

    - by Dan P
    Assuming a Read Committed Snapshot transaction isolation setting, is the following statement "atomic" in the sense that you won't ever "lose" a concurrent increment? update mytable set counter = counter + 1 I would assume that in the general case, where this update statement is part of a larger transaction, that it wouldn't be. For example, I think this scenario is possible: update the counter within transaction #1 do some other stuff in transaction #1 update the counter with transaction #2 commit transaction #2 commit transaction #1 In this situation, wouldn't the counter end up only being incremented by 1? Does it make a difference if that is the only statement in a transaction? How does a site like stackoverflow handle this for its question view counter? Or is the possibility of "losing" some increments just considered acceptable?

    Read the article

  • How can I prevent users from taking screenshots of my application window?

    - by Midday
    What are some methods to prevent screenshots from being taken, if any? I've considered setting the "Print Screen" button as a hotkey, which makes the window fuzzy. However, there would be the problem of other 3rd party screenshot tools. How can I prevent their use? Why would I want such a thing? The idea is to create a chat client which you can't share the chatted information with others, not by copy & paste nor by print screen... Looking for general ideas or suggestions rather than actual code.

    Read the article

  • code for find out nth larget number in an array by using perl

    - by user136104
    I have written following code in perl #!/usr/bin/perl @array =(3,6,8,1,2); my $second_largest =0; my $largest = 0; for (@array) { if($_ > $largest) { $second_largest = $largest; $largest = $_; } if($_ > $second_largest && $_ < $largest) { $second_largest = $_; } } print "Second largest::".$second_largest; print "largest::".$largest; But I need a general code to find out "Nth" largest and smallest number of an array Plz help me

    Read the article

  • Is there a way in PHP to check if a directory is a symlink?

    - by tixrus
    The title says it all. I have symlinks to certain directories because the directories' names have non English characters that I got fed up trying to get apache's rewrite rules to match. There's a bounty on that question http://stackoverflow.com/questions/2916194/trouble-with-utf-8-chars-apache2-rewrite-rulesif anyone wants to go for it, and from the looks of things a lot of people would like to see a general solution to this problem, but meanwhile I made a plain ascii symlink to each of these offending directories. Now the rewrite rules are back to just alpha and _ and - and my security concerns are less and it loads the resources I want. But I still need the actual target directory name for display purposes. I googled "PHP directory info, PHP symlink" but didn't find anything. I need to do something like this: if (is_symlink($myResDirName)) { $realDirName = follow_symlink($myResDirName); }

    Read the article

  • CFLAGS vs CPPFLAGS

    - by EB
    I understand that CFLAGS (or CXXFLAGS for C++) are for the compiler, whereas CPPFLAGS is used by the preprocessor. But I still don't understand the difference. I need to specify an include path for a header file that is included with #include -- because #include is a preprocessor directive, is the preprocessor (CPPFLAGS) the only thing I care about? Under what circumstances do I need to give the compiler an extra include path? In general, if the preprocessor finds and includes needed header files, why does it ever need to be told about extra include directories? What use is CFLAGS at all? (In my case, I actually found that BOTH of these allow me to compile my program, which adds to the confusion... I can use CFLAGS OR CPPFLAGS to accomplish my goal (in autoconf context at least). What gives?)

    Read the article

  • Synchronising local and remote DB

    - by nico
    Hi everyone, I have a general question about DB synchronisation. So, I'm developing a website locally (PHP + MySQL) and I would like to be able to synchronise at least the structure (and maybe the contents) of the two DB when one of the two is changed (normally I would change the local copy). Right now what I'm doing is to use mysqldump to dump the modified tables and then import them in the remote DB or do it by hand if the changes are minimal. However I find this tedious and error-prone. For the PHP I'm currently using Quanta+ which has the handy feature of finding files that have changed and just upload those. Is there something similar for MySQL? Otherwise how do you keep your DBs synchronised? Thanks nico PS: I'm sorry if this was already asked, I saw other questions that deal with similar topics, but couldn't really find an answer.

    Read the article

  • How can I efficiently select several unique random numbers from 1 to 50, excluding x?

    - by Cocorico
    I have 2 numbers which are between 0 and 49. Let's call them x and y. Now I want to get a couple of other numbers which are not x or y, but are also between 0 and 49 (I am using Objective C but this is more of a general theory question I think?). Method I thought of is: int a; int b; int c; do { a = arc4random() % 49; } while ((a == x) || (a == y)); do { b = arc4random() % 49; } while ((b == x) || (b == y) || (b == a)); do { c = arc4random() % 49; } while ((c == x) || (c == y) || (c == a) || (c == b)); But it seem kind of bad to me, I don't know, I am just trying to learn to be a better programmer, what would be the most elegant way to do this for best practices?

    Read the article

  • Interesting interview question. .Net

    - by rahul
    Coding Problem NumTrans There is an integer K. You are allowed to add to K any of its divisors not equal to 1and K. The same operation can be applied to the resulting number and so on. Notice that starting from the number 4, we can reach any composite number by applying several such operations. For example, the number 24 can be reached starting from 4 using 5 operations: 468121824 You will solve a more general problem. Given integers n and m, return the minimal number of the described operations necessary to transform n into m. Return -1 if m can't be obtained from n. Definition Method signature: int GetLeastCount (int n, int m) Constraints N will be between 4 and 100000, inclusive. M will be between N and 100000, inclusive. Examples 1) 4 576 Returns: 14 The shortest order of operations is: 468121827365481108162243324432576 2) 8748 83462 Returns: 10 The shortest order of operations is: 874813122196832624439366590497873283106834488346083462 3) 4 99991 Returns: -1 The number 99991 can't be obtained because it’s prime!

    Read the article

  • Ampersand in link description text?

    - by kitenski
    I am validating my site using validator.w3.org and have an issue where there is a & in my link description text. ie this is taken from the source <a class='tag' href='/php/iphone software.php?function=developer&amp;dev=witch%26wizards+inc.&amp;store=143441'>witch&wizards inc.</a> Which gives me this error in the validator Line 188, Column 540: cannot generate system identifier for general entity "wizards" …6wizards+inc.&store=143441'witch&wizards inc. If I urlencode the description then the validation passes, but the user then sees the text displayed urlencoded, ie Developer witch%26wizards+inc. However I believe it's much more user friendly if this was displayed unencoded, ie Developer witch&wizards inc. Is there a way to pass validation but still have user friendly text displayed? Thanks, Greg

    Read the article

  • How do I select the number of distinct days in a date range?

    - by isme
    I'm trying to use the T-SQL function DATEDIFF to select the number of distinct dates in a time period. The following query: SELECT DATEDIFF(DAY, '2012-01-01 01:23:45', '2012-01-02 01:23:45') selects 1, which is one less than I want. There are two distinct dates in the range: 2012-01-01 and 2012-01-02. It is not correct to add one to the result in the general case. The following query: SELECT DATEDIFF(DAY, '2012-01-01 00:00:00', '2012-01-02 00:00:00') selects 1, which is correct, because there is only one distinct date in the range. I'm sure there is a simple bit of arithmetic that I'm missing to calculate this. Can someone help me?

    Read the article

  • Best practices retrieving XML/stream from HTTP in Android

    - by Jeffrey
    Hello everyone, what are the best practices parsing XML from an HTTP resource in Android? I've been using HttpURLConnection to retrieve an InputStream, wrapping it with a BufferedInputStream, and then using SAX to parse the buffered stream. For the most part it works, though I do receive error reports of SocketTimeoutException: The operation timed out or general parsing error. I believe it's due to the InputStream. Would using HttpClient instead of HttpURLConnection help? If yes, why? Should the stream be output to a file, having the file parsed instead of the stream? Any input or direction would be greatly appreciated. Thanks for your time.

    Read the article

  • How do I sum up weighted arrays in PHP?

    - by christian studer
    Hod do I multiply the values of a multi-dimensional array with weigths and sum up the results into a new array in PHP or in general? The boring way looks like this: $weights = array(0.25, 0.4, 0.2, 0.15); $values = array ( array(5,10,15), array(20,25,30), array(35,40,45), array(50,55,60) ); $result = array(); for($i = 0; $i < count($values[0]); ++$i) { $result[$i] = 0; foreach($weights as $index => $thisWeight) $result[$i] += $thisWeight * $values[$index][$i]; } Is there a more elegant solution?

    Read the article

  • LogCat acting patchy

    - by OceanBlue
    The LogCat output in eclipse suddenly started weird. It sometimes shows all the output as expected. Other times it just doesn't show anything - is completely blank. After some internet research, I thought Mylyn plugin might be responsible. So I tried de-selecting "Mylyn Tasks UI" & "Mylyn Team UI" on eclipse Window -- Preferences -- General -- Startup and Shutdown -- programs that are started at startup. No Luck. Has anyone else encountered & solved this problem?

    Read the article

  • Flex Builder 3 Unclosable Editor Windows

    - by Sam Goldman
    See: http://i.imgur.com/pQNQh.png Somehow I made this happen and I don't know how to undo it. The image linked above shows my Flex Builder session. The largest section of the window is the editor. Initially, there was a blank window on the screen so I tried closing it, but I couldn't. Then I tried dragging it and realized I could drag it into a corner of itself, hence all the nested windows. I have no idea how to close these windows or simply reset the view. I went to the preferences under General Perspectives, but the "reset" button was disabled for every available perspective. Help?

    Read the article

  • Candidate Elimination Question---Please help!

    - by leon
    Hi , I am doing a question on Candidate Elimination Algorithm. I am a little confused with the general boundary G. Here is an example, I got G and S to the fourth case, but I am not sure with the last case. Sunny,Warm,Normal,Strong,Warm,Same,EnjoySport=yes Sunny,Warm,High,Strong,Warm,Same,EnjoySport=yes Rainy,Cold,High,Strong,Warm,Change,EnjoySport=no Sunny,Warm,High,Strong,Cool,Change,EnjoySport=yes Sunny,Warm,Normal,Weak,Warm,Same,EnjoySport=no What I have here is : S 0 :{0,0,0,0,0,0} S 1 :{Sunny,Warm,Normal,Strong,Warm,Same} S 2 , S 3 : {Sunny,Warm,?,Strong,Warm,Same} S 4 :{Sunny,Warm,?,Strong,?,?} G 4 :{Sunny,?,?,?,?,?,?,Warm,?,?,?,?} G 3 :{Sunny,?,?,?,?,?,?,Warm,?,?,?,?,?,?,?,?,?,Same} G 0 , G 1 , G 2 : {?,?,?,?,?,?} What would be the result of G5? Is it G5 empty? {}? or {???Strong??) ? Thanks

    Read the article

  • PHP Thumbnail image generator works, but consistently awaits 90% of its loadtime! Why?

    - by Sam
    Hi folks, This is the follow-up question from this general page load speed question. This question which will focus only, entirely and specifically on the thumbnail generator PHP code with the question: What's causing the 97% delays on these tiny thumbnails? Measuring only 3 ~ 5 kb each, this is strange indeed! Even after 7 orso bounty-rounds and 100 upvotes, the images are still doing nothing for over 97% of the time. It works allright, but it could be so much faster! ZAM, my pet robot, was so annoyed by not knowing why, he just pulled out some cords! Silly metal box... (I have asked permission from the original author, to put temporarily segments of the code online that I think could be the problem, after which I will remove all code, except the several lines that were the direct cause of this issue here to match the answer. This will be the free opportunity to perfect/speedup his otherwise already to my opinion vert versatile and userfriendly thumbnail generator.)

    Read the article

  • Track each request to the website using HttpModule

    - by stacker
    I want to save each request to the website. In general I want to include the following information: User IP, The web site url, user-if-exist, date-time. Response time, response success-failed status. Is it reasonable to collect the 1 and 2 in the same action? (like same HttpModule)? Do you know about any existing structure that I can follow that track every request/response-status to the website? The data need to be logged to sql server.

    Read the article

  • Recommend an algorithms exercise book?

    - by Parappa
    I have a little book called Problems on Algorithms by Ian Parberry which is chock full of exercises related to the study of algorithms. Can anybody recommend similar books? What I am not looking for are recommendations of good books related to algorithms or the theory of computation. Introduction to Algorithms is a good one, and of course there's the Knuth stuff. Ideally I want to know of any books that are light on instructional material and heavy on sample problems. In a nutshell, exercise books. Preferably dedicated to algorithms rather than general logic or other math problems. By the way, the Parberry book does not seem to be in print, but it is available as a PDF dowload.

    Read the article

  • sql query question / count

    - by scheibenkleister
    Hi, I have houses that belongs to streets. A user can buy several houses. How do I find out, if the user owns an entire street? street table with columns (id/name) house table with columns (id/street_id [foreign key] owner table with columns (id/house_id/user_id) [join table with foreign keys] So far, I'm using count which returns the result: select count(*), street_id from owner left join house on owner.house_id = house.id group by street_id where user_id = 1 count(*) | street_id 3 | 1 2 | 2 A more general count: select count(*) from house group by street_id returns: count(*) | street_id 3 | 1 3 | 2 How can I find out, that user 1 owns the entire street 1 but not street 2? Thanks.

    Read the article

  • Find/parse server-side <?abc?>-like tags in html document

    - by Iggyhopper
    I guess I need some regex help. I want to find all tags like <?abc?> so that I can replace it with whatever the results are for the code ran inside. I just need help regexing the tag/code string, not parsing the code inside :p. <b><?abc print 'test' ?></b> would result in <b>test</b> Edit: Not specifically but in general, matching (<?[chars] (code group) ?>)

    Read the article

  • "Socket operation on non-socket" error due to strange syntax

    - by Robert S. Barnes
    I ran across the error Socket operation on non-socket in some of my networking code when calling connect and spent a lot of time trying to figure out what was causing it. I finally figured out that the following line of code was causing the problem: if ((sockfd = socket( ai->ai_family, ai->ai_socktype, ai->ai_protocol) < 0)) { See the problem? Here's what the line should look like: if ((sockfd = socket( ai->ai_family, ai->ai_socktype, ai->ai_protocol)) < 0) { What I don't understand is why the first, incorrect line doesn't produce a warning. To put it another way, shouldn't the general form: if ( foo = bar() < baz ) do_something(); look odd to the compiler, especially running with g++ -Wall -Wextra? If not, shouldn't it at least show up as "bad style" to cppcheck, which I'm also running as part of my compile?

    Read the article

  • cached schwartzian transform

    - by davidk01
    I'm going through "Intermediate Perl" and it's pretty cool. I just finished the section on "The Schwartzian Transform" and after it sunk in I started to wonder why the transform doesn't use a cache. In lists that have several repeated values the transform recomputes the value for each one so I thought why not use a hash to cache results. Here' some code: # a place to keep our results my %cache; # the transformation we are interested in sub foo { # expensive operations } # some data my @unsorted_list = ....; # sorting with the help of the cache my @sorted_list = sort { ($cache{$a} or $cache{$a} = &foo($a)) <=> ($cache{$b} or $cache{$b} = &foo($b)) } @unsorted_list; Am I missing something? Why isn't the cached version of the Schwartzian transform listed in books and in general just better circulated because on first glance I think the cached version should be more efficient?

    Read the article

  • Maven2 compiles my tests, but doesn't run them

    - by Vincenzo
    I have a simple Maven2 project with tests written for TestNG. When I say mvn test Maven2 compiles my test, but don't run them. I already checked this page: http://maven.apache.org/general.html#test-property-name. This is not my case. Anybody can help? My directory structure: pom.xml src main java com ... test java com ... target classes <— .class files go there test-classes <— .class files with tests go there This is what I see if I run mvn -X test (end of the log): ... [INFO] Surefire report directory: <mydir>/target/surefire-reports Forking command line: /bin/sh -c cd <mydir> && /System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/Home/bin/java -jar /var/folders/+j/+jAx0g2xGA8-Ns9lWNOWgk+++TM/-Tmp-/surefirebooter7645642850235508331.jar /var/folders/+j/+jAx0g2xGA8-Ns9lWNOWgk+++TM/-Tmp-/surefire4544000548243268568tmp /var/folders/+j/+jAx0g2xGA8-Ns9lWNOWgk+++TM/-Tmp-/surefire7481499683857473873tmp ------------------------------------------------------- T E S T S ------------------------------------------------------- Running TestSuite Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.191 sec

    Read the article

< Previous Page | 191 192 193 194 195 196 197 198 199 200 201 202  | Next Page >