Search Results

Search found 747 results on 30 pages for 'kyle terry'.

Page 8/30 | < Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >

  • Deliberately crashing an external process under Windows

    - by Terry
    I would like to synthesise a native code fault. This is so that we can see where in particular some debugging output gets put when that occurrs. Pskill (from Sys-Internals) causes a graceful exit. DotCrash.exe doesn't seem to be available anymore from Microsoft directly. Is there any way to externally cause a crash in a process?

    Read the article

  • How do I add NSDecimalNumbers?

    - by Terry B
    OK this may be the dumb question of the day, but supposing I have a class with : NSDecimalNumber *numOne = [NSDecimalNumber numberWithFloat:1.0]; NSDecimalNumber *numTwo = [NSDecimalNumber numberWithFloat:2.0]; NSDecimalNumber *numThree = [NSDecimalNumber numberWithFloat:3.0]; Why can't I have a function that adds those numbers: - (NSDecimalNumber *)addThem { return (self.numOne + self.numTwo + self.numThree); } I apologize in advance for being an idiot, and thanks!

    Read the article

  • Bash variable kills script execusion

    - by Kyle Terry
    Sorry if this is better suited at serverfault, but I think it learns more towards the programming side of things. I have some code that's going into /etc/rc.local to detect what type of touch screen monitor is plugged in and changes out the xorg.conf before launching X. Here is a small snippet: CURRENT_MONITOR=`ls /dev/usb | grep 'egalax_touch\|quanta_touch'` case $CURRENT_MONITOR in '') CURRENT_MONITOR='none' ;; esac If one of those two touch screens is plugged in, it works just fine. If any other monitor is plugged in, it stops at the "CURRENT_MONITOR=ls /dev/usb | grep 'egalax_touch\|quanta_touch'." For testing I touched two files. One before creating CURRENT_MONITOR and one after CURRENT_MONITOR and only file touched before is created. I'm not a bash programmer so this might be something very obvious.

    Read the article

  • Bash variable kills script execution

    - by Kyle Terry
    Sorry if this is better suited at serverfault, but I think it learns more towards the programming side of things. I have some code that's going into /etc/rc.local to detect what type of touch screen monitor is plugged in and changes out the xorg.conf before launching X. Here is a small snippet: CURRENT_MONITOR=`ls /dev/usb | grep 'egalax_touch\|quanta_touch'` case $CURRENT_MONITOR in '') CURRENT_MONITOR='none' ;; esac If one of those two touch screens is plugged in, it works just fine. If any other monitor is plugged in, it stops at the "CURRENT_MONITOR=ls /dev/usb | grep 'egalax_touch\|quanta_touch'." For testing I touched two files. One before creating CURRENT_MONITOR and one after CURRENT_MONITOR and only file touched before is created. I'm not a bash programmer so this might be something very obvious.

    Read the article

  • Python, implementing proxy support for a socket based application (not urllib2)

    - by Terry Felkrow
    Hey guys, I am little stumped: I have a simple messenger client program (pure python, sockets), and I wanted to add proxy support (http/s, socks), however I am a little confused on how to go about it. I am assuming that the connection on the socket level will be done to the proxy server, at which point the headers should contain a CONNECT + destination IP (of the chat server) and authentication, (if proxy requires so), however the rest is a little beyond me. How is the subsequent connection handled, specifically the reading/writing, etc... Are there any guides on proxy support implementation for socket based (tcp) programming in Python? Thank you

    Read the article

  • Decorator Module Standard

    - by Kyle Terry
    I was wondering if it's frowned upon to use the decorator module that comes with python. Should I be creating decorators using the original means or is it considered okay practice to use the module?

    Read the article

  • What's your favorite implementation of producing the fibonacci sequence?

    - by Terry Donaghe
    Best, most creative, most clever, fastest, smallest, written in weirdest language, etc etc. For those not familiar with this staple of programming exam question / interview question, check this out: Fibonacci Sequence at Wikipedia The question would be, write a simple program which will spit out the first n digits of the Fibonacci sequence. So, if n == 12, we produce: 0 1 1 2 3 5 8 13 21 34 55 89 144 Your implementation becomes more interesting when you set n to larger values. How long does it take your implementation to return a 25 digit sequence? How about 100?

    Read the article

  • What Visual C++ references are worth a look for a Java programmer looking to get up to speed?

    - by Terry V.
    I have a lot of experience with Java/OO. There are tons of C++ tutorials/references out there, but I was wondering if there are a few key ones that a Java programmer might find useful when making the transition. I will be moving from server-side J2EE to Windows Visual C++ desktop programming. I have googled and found tons of resources, but am overwhelmed and don't know where to best spend my time. I have only a few days to get a good start. Is Visual Studio Express / Microsoft Visual C++ the best IDE for me to start with? Also, any words of wisdom from others who know and work with both languages?

    Read the article

  • How do we simplify this kind of code in Java? Something like macros in C?

    - by Terry Li
    public static boolean diagonals(char[][] b, int row, int col, int l) { int counter = 1; // because we start from the current position char charAtPosition = b[row][col]; int numRows = b.length; int numCols = b[0].length; int topleft = 0; int topright = 0; int bottomleft = 0; int bottomright = 0; for (int i=row-1,j=col-1;i>=0 && j>=0;i--,j--) { if (b[i][j]==charAtPosition) { topleft++; } else { break; } } for (int i=row-1,j=col+1;i>=0 && j<=numCols;i--,j++) { if (b[i][j]==charAtPosition) { topright++; } else { break; } } for (int i=row+1,j=col-1;i<=numRows && j>=0;i++,j--) { if (b[i][j]==charAtPosition) { bottomleft++; } else { break; } } for (int i=row+1,j=col+1;i<=numRows && j<=numCols;i++,j++) { if (b[i][j]==charAtPosition) { bottomright++; } else { break; } } return topleft + bottomright + 1 >= l || topright + bottomleft + 1 >= l; //in this case l is 5 } After I was done posting the code above here, I couldn't help but wanted to simplify the code by merging the four pretty much the same loops into one method. Here's the kind of method I want to have: public int countSteps(char horizontal, char vertical) { } Two parameters horizontal and vertical can be either + or - to indicate the four directions to walk in. What I want to see if possible at all is i++; is generalized to i horizontal horizontal; when horizontal taking the value of +. What I don't want to see is if or switch statements, for example: public int countSteps(char horizontal, char vertical) { if (horizontal == '+' && vertical == '-') { for (int i=row-1,j=col+1;i>=0 && j<=numCols;i--,j++) { if (b[i][j]==charAtPosition) { topright++; } else { break; } } } else if (horizontal == '+' && vertical == '+') { for (int i=row+1,j=col+1;i>=0 && j<=numCols;i++,j++) { if (b[i][j]==charAtPosition) { topright++; } else { break; } } } else if () { } else { } } Since it is as tedious as the original one. Note also that the comparing signs for the loop condition i>=0 && j<=numCols; for example, >= && <= have correspondence with the value combination of horizontal and vertical. Sorry for my bad wording, please let me know if anything is not clear.

    Read the article

  • Another Nim's Game Variant

    - by Terry Smith
    Given N binary sequence Example : given one sequence 101001 means player 0 can only choose a position with 0 element and cut the sequence from that position {1,101,1010} player 1 can only choose a position with 1 element ans cut the sequence from that position {null,10,101000} now player 0 and player 1 take turn cutting the sequence, on each turn they can cut any one non-null sequence, if a player k can't make a move because there's no more k element on any sequence, he lose. Assume both player play optimally, who will win ? I tried to solve this problem with grundy but i'm unable to reduce the sequence to a grundy number because it both player don't have the same option to move. Can anyone give me a hint to solve this problem ?

    Read the article

  • How many databases to support eCommerce?

    - by Terry Lorber
    I have a system with two databases, one that the customer-facing website uses, the second that is used by the "backroom" order-fulfillment system. I've been asked to run queries from the website to the backroom system. I'd rather not, it seems risky to allow web-based request to run unheeded on the internal system. Additionally, this means opening up routing in the firewall to allow external connections to the internal server. What's the best practice for eCommerce? Run the entire company off of one database? Or individual databases for each system, and middleware to connect them? Sometimes it might be necessary for the web application to pull date from the internal system, but not based on an HTTP request from the internet. I'm sure the best answer is "it depends!" So, if people have a rule of thumb for when to use middleware and when not to, I'd like to here it.

    Read the article

  • Why this mouseout will be called when i move out of li instead of ul?

    - by terry
    i want to call mouseout of ul tag, but it looks it will call mouseout as well when i move between two li tags, what's wrong? how can i make it work when i move mouse out of the ul? thanks a lot! $(document).ready(function(){ $("#info").live("mouseout", function(){ console.log('mouseout'); }); }); HTML <div id="latest"> <ul id="info"> <li>test1</li> <li>test2</li> </ul> </div>

    Read the article

  • Null reference for first memory address between 0 - 65535

    - by Terry
    I would like to understand a bit more about memory and I was unable to find it from Google, please forgive me if this is silly question. How come the following code, accessing memory address 0(and up to 65535) in C# would throw NullReferenceException byte* pointer = (byte*)0; byte test = *pointer; Thanks a lot in advance!

    Read the article

  • whether rand_r is real thread safe?

    - by terry
    Well, rand_r function is supposed to be a thread safe function. However, by its implementation, I cannot believe it could make itself not change by other threads. Suppose that two threads will invoke rand_r in the same time with the same variable seed. So read-write race will occur. The code rand_r implemented by glibc is listed below. Anybody knows why rand_r is called thread safe? int rand_r (unsigned int *seed) { unsigned int next = *seed; int result; next *= 1103515245; next += 12345; result = (unsigned int) (next / 65536) % 2048; next *= 1103515245; next += 12345; result <<= 10; result ^= (unsigned int) (next / 65536) % 1024; next *= 1103515245; next += 12345; result <<= 10; result ^= (unsigned int) (next / 65536) % 1024; *seed = next; return result; }

    Read the article

  • How do I prevent Window resizing when the Workstation is Locked then Unlocked?

    - by Terry
    We have an application that is run in multi-monitor environments. Users normally have the application dialog spread out to span multiple mointors. If the user locks the workstation, and then unlocks it, our application is told to resize. Our users find this behavior frustrating, as they then spend some time restoring the previous layout. We're not yet sure whether it is the graphics driver requesting the resize or Windows. Hopefully through this question, it will become clearer which component is responsible, Popular applications like (File) Explorer and Firefox behave the same way in this setup. To replicate just: open Explorer (Win+E) drag the Explorer window to being horizontally larger than 1 screen lock workstation (Win+L), unlock the application should now resize to being solely on 1 screen How do I prevent Window resizing when the Workstation is Locked then Unlocked? Will we need to code in checks for (un)locking? Is there another mechanism we're not aware of?

    Read the article

  • Big-Oh running time of code in Java (are my answers accurate

    - by Terry Frederick
    the Method hasTwoTrueValues returns true if at least two values in an array of booleans are true. Provide the Big-Oh running time for all three implementations proposed. // Version 1 public boolean has TwoTrueValues( boolean [ ] arr ) { int count = 0; for( int i = 0; i < arr. length; i++ ) if( arr[ i ] ) count++; return count >= 2; } // Version 2 public boolean hasTwoTrueValues( boolean [ ] arr ) { for( int i = 0; i < arr.length; i++ ) for( int j = i + 1; j < arr.length; j++ ) if( arr[ i ] && arr[ j ] ) return true; } // Version 3 public boolean hasTwoTrueValues( boolean [ ] arr ) { for( int i = 0; i < arr.length; i++ if( arr[ i ] ) for( int j = i + 1; j < arr.length; j++ ) if( arr[ j ] ) return true; return false; } For Version 1 I say the running time is O(n) Version 2 I say O(n^2) Version 3 I say O(n^2) I am really new to this Big Oh Notation so if my answers are incorrect could you please explain and help.

    Read the article

  • ArchBeat Link-o-Rama for December 11, 2012

    - by Bob Rhubart
    Good To Know - Conflicting View Objects and Shared Entity | Andrejus Baranovskis Oracle ACE Director Andrejus Baranovskis shares his thoughts—and a sample application—dealing with an "interesting ADF behavior" encountered over the weekend. Patching Oracle Exalogic - Updating Linux on the Compute Nodes - Part 1 | Jos Nijhoff Jos Nijhoff launches a series of posts the deal with "patching the operating system on the modified Sun Fire X4170 M2 servers...dubbed compute nodes in Exalogic terminology." Expanding on requestaudit - Tracing who is doing what...and for how long | Kyle Hatlestad "One of the most helpful tracing sections in WebCenter Content (and one that is on by default) is the requestaudit tracing," says Oracle Fusion Middleware A-Team architect Kyle Hatlestad. Get up close and technical in his post. Oracle Data Integrator Presentation from NYOUG Webinar | Gurcan Orhan Oracle ACE Director and award-winning data warehouse architect Gurcan Orhan shares his presentation from the recent NYOUG LI SIG. SOA 11g Technology Adapters – ECID Propagation | Greg Mally "Many SOA Suite 11g deployments include the use of the technology adapters for various activities including integration with FTP, database, and files to name a few," says Oracle Fusion Middleware A-Team member Greg Mally. "Although the integrations with these adapters are easy and feature rich, there can be some challenges from the operations perspective." Greg's post focuses on technical tips for dealing with one of these challenges. Missing Duties for RUP3 upgrade in Fusion Applications Richard from the Oracle Fusion Middleware A-Team explains how to safely apply policy store changes in thirteen easy steps. Thought for the Day "Well over half of the time you spend working on a project (on the order of 70 percent) is spent thinking, and no tool, no matter how advanced, can think for you." — Frederick P. Brooks Source: SoftwareQuotes.com

    Read the article

  • Silverlight Cream for May 18, 2010 -- #864

    - by Dave Campbell
    In this Issue: Jesse Liberty, Chris Koenig, Kyle McClellan, Kunal Chowdhury(-2-), Tim Heuer, and Jonathan van de Veen. Shoutout: René Schulte has posted a SLARToolkit Beginner's Guide Erik Mork and the Sparkling Podcast crew posted Silverlight Week – Silverlight Android? John Papa opens up a dialog: Ask the Experts on Silverlight TV ... get your questions answered! From SilverlightCream.com: Windows Phone 7 For Silverlight Programmers Jesse Liberty's starting a series on WP7, so you obviously don't want to miss this... source, commentary, external links, how-to's... what more could you ask for?? WP7 Part 3: Navigation Chris Koenig is revamping his WP7 application to use Community Megaphone instead of Nerd Dinner and in this episode 3 he's looking into Navigation ... definitely good stuff here. RIA Services Authentication Out-Of-Browser Kyle McClellan has code up demonstrating how to get around the fact that the Browser networking stack handles cookies differently than the client networking stack used OOB, and achieve forms authentication OOB. How to work with the Silverlight BusyIndicator? Kunal Chowdhury has a post up talking about the busy indicator and how to use it to show an active indicator while disabling other content. Drag and Drop Operation in Silverlight ListBox In a second entry, Kunal Chowdhury has a nice long post displaying drag-and-drop within and between ListBox controls. Silverlight 4 Tools, WCF RIA Services and Themes Released As usual, Tim Heuer has a great post up about the new releases not only for those with 'clean' machines, but also instructions for those that have been playing along. Advanced printing in Silverlight 4 Just after a post on printing yesterday, Jonathan van de Veen has a post up at SilverlightShow on printing as well, and is demonstrating fitting the text to the page and printing multiple pages. Stay in the 'Light! Twitter SilverlightNews | Twitter WynApse | WynApse.com | Tagged Posts | SilverlightCream Join me @ SilverlightCream | Phoenix Silverlight User Group Technorati Tags: Silverlight    Silverlight 3    Silverlight 4    Windows Phone MIX10

    Read the article

  • Cannot reinstall MySql in 11.10 - ERROR: There's not enough space in /var/lib/mysql/

    - by Robin McCain
    I've tried it all (removing all the packages associated with MySQL) but keep getting stuff like this: Preconfiguring packages ... (Reading database ... 142196 files and directories currently installed.) Unpacking mysql-server-5.1 (from .../mysql-server-5.1_5.1.63-0ubuntu0.11.10.1_amd64.deb) ... ERROR: There's not enough space in /var/lib/mysql/ dpkg: error processing /var/cache/apt/archives/mysql-server-5.1_5.1.63-0ubuntu0.11.10.1_amd64.deb (--unpack): subprocess new pre-installation script returned error exit status 1 Errors were encountered while processing: /var/cache/apt/archives/mysql-server-5.1_5.1.63-0ubuntu0.11.10.1_amd64.deb E: Sub-process /usr/bin/dpkg returned an error code (1) Here is my drive space map. root@kyle:/# df Filesystem 1K-blocks Used Available Use% Mounted on /dev/mapper/kyle-root 59361428 59021768 0 100% / udev 1014052 8 1014044 1% /dev tmpfs 409304 1476 407828 1% /run none 5120 0 5120 0% /run/lock none 1023256 0 1023256 0% /run/shm /dev/sda1 233191 46888 173862 22% /boot /dev/md0 1922858288 1048513192 776669500 58% /media/array The root volume actually only has about 10 gigabytes in use on the hard drive (which has a 60 gig partition). /dev/md0 is a 2 TB raid array.

    Read the article

< Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >