Search Results

Search found 559 results on 23 pages for 'terry alexander'.

Page 6/23 | < Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >

  • 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

  • Silverlight Cream for April 28, 2010 -- #850

    - by Dave Campbell
    In this Issue: Giorgetti Alessandro, Alexander Strauss, Mahesh Sabnis, Andrea Boschin, Maxim Goldin, Peter Torr, Wolf Schmidt, and Marlon Grech. Shoutout: Koen Zwikstra announced a SL4 update: Silverlight Spy 3.0.0.11 Adam Kinney posted a WTF Step by Step guide to installing Silverlight Tools David Makogon posted his materials from a presentation: RockNUG April 2010 Materials: Silverlight 4 From SilverlightCream.com: Silverlight, M-V-VM ... and IoC - part 4 Giorgetti Alessandro isn't wasting any time... he's already gotten Part 4 of his MVVM, IoC, and Silverlight series up. He's discussing commanding. He gives some good external links and develops in his own direction as well. Application Partitioning with MEF, Silverlight and Windows Azure – Part II Alexander Strauss has the second and final part of his MEF/Silverlight/Azuer posts up, describing getting XAP information from Azure Blob storage. Simple Databinding and 3-D Features using Silverlight in Windows Phone 7 (WP7) Mahesh Sabnis has a post up combining DataBinding and 3D displays on WP7 ... good long tutorial and source. Keeping an ObservableCollection sorted with a method override Andrea Boschin details the reasons behind his need for having a sorted ObservableCollection, then hands over the code he used to do so. VS2010: Silverlight 4 profiling Maxim Goldin posted about profiling Silverlight 4 in VS2010. It's not overly straightforward but once you do it a couple times, not a big deal ... check out the comments as well. Peter Torr: Mock Location APIs from my Mix10 Talk A discussion came up on the insider's list this morning asking about Location Service in the emulator. Laurent Bugnion pointed us at Peter Torr's Mock Location from his MIX10 talk. Finding the "real" templates and generic.xaml in Silverlight core or library assemblies, by using .NET Reflector Wolf Schmidt at the Silverlight SDK has a post up about using .NET Reflector to rat around in Silverlight core or library assemblies. How does MEFedMVVM compose the catalogs and how can I override the behavior? – MEFedMVVM Part 4 Marlon Grech has Part 4 of his MEFedMVVM series up and this one is for advanced use of MEFedMVVM... where you're writing a composer and how that would be different for Silverlight and WPF... oh yeah, and what is a composer as well :) 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

  • La NSA dément avoir espionné l'Europe et ses dirigeants, « ce sont les Européens qui surveillent leurs citoyens dans le cadre des missions de l'OTAN »

    La NSA n'espionne pas l'Europe et ses dirigeants, ce sont les européens qui espionnent leurs citoyens dans le cadre de missions de l'OTAN» Le chef de la NSA, le général Keith Alexander, a vivement démenti tout ce que l'on pouvait voir sur les médias du monde jusqu'à maintenant. Profitant d'une audition devant la commission du renseignement de la Chambre des représentants il a annoncé calmement, mais fermement que la NSA n'avait rien mis en place pour espionner les citoyens européens.Si la NSA...

    Read the article

  • How to Convert Your Nice Designs to Wordpress

    If you already spent ample time on the net, you have probably heard about WordPress before. It is an easy to use blog platform that also seconds as a fully competent content management system all ove... [Author: Kewin Alexander - Web Design and Development - April 12, 2010]

    Read the article

  • Silverlight Cream for April 27, 2010 -- #849

    - by Dave Campbell
    In this Issue: Mike Snow, Kunal Chowdhury, Giorgetti Alessandro, Alexander Strauss, Corey Schuman, Kirupa, John Papa, Miro Miroslavov, Michael Washington, and Jeremy Likness. Shoutouts: Erik Mork and crew have posted their latest This Week In Silverlight April 23 2010 The Silverlight Team announced Microsoft releases Silverlight-powered Windows Intune beta Jesse Liberty has posted his UK and Ireland Slides and Links The Expression Blend and Design Blog reports a Minor Update to The Expression Blend 4 Release Candidate From SilverlightCream.com: Silverlight Tip of the Day #6 – Toast Notifications Mike Snow has Tip #6 up today and it's about Toast notifications in OOB apps: Restrictions, creation, showing, and the code. Silverlight Tutorials Chapter 2: Introduction to Silverlight Application Development Part 2 of Kunal Chowdhury's Introductory tutorial set is up ... he's covering how to create a Silverlight project, what's contained in it, and creating a User Control. Silverlight, M-V-VM ... and IoC - part 3 Giorgetti Alessandro has part 3 of his Silverlight, IOC, and MVVM series up... this one with an example using the code discussed previously. The project is on CodePlex, and he's not done with the series. Application Partitioning with MEF, Silverlight and Windows Azure – Part I Alexander Strauss is discussing Silverlight and MEF for loosely-coupled and partitioned apps. He's also using Azure in this discussion. geekSpeak Recording - Five Key Developer Features in Expression Blend with Corey Schuman Check out the latest geekSpeak on Channel 9 where Corey Schuman talks about the 5 key Developer Features in Expression Blend that will improve your productivity. Using the ChangePropertyAction Kirupa is discussing and demonstrating ChangePropertyAction. Check out the demo near the top of the post, then read how to do it, and download the source. 3 Free Silverlight Demos John Papa blogged about the 2 demos (with source) that have been updated to SL4, and a new one all by Microsoft Luminaries Karen Corby, Adam Kinney, Mark Rideout, Jesse Bishop, and John Papa: "ScrapBook", "HTML and Video Puzzle", and "Rich Notepad". Floating Visual Elements I like Miro Miroslavov's comment: "every Silverlight application “must” have some objects floating around in a quite 3D manner" :) ... well they do that on the CompletIT site, and this is part 2 of their explanation of how all that goodness works. MVVM – A Total Design Change Of Your Application With No Code With some Blend goodness, Michael Washington completely reorganizes the UI of an MVVM application without touching any code ... project included MVVM with Transaction and View Locator Example Jeremy Likness responded to reader requests and has an example up, with explanation, of marrying his last two posts: transactions with MVVM and View Model Locator. 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

  • Book Review: Microsoft SQL Server 2008 Analysis Services Unleashed

    - by Greg Low
    Yet another book that I started re-reading last week (but haven't finished again yet as it's so large) is Microsoft SQL Server 2008 Analysis Services Unleashed by Irina Gorbach, Alexander Berger and Edward Melomed. This book has always left me with mixed feelings. The authors clearly offer expert level knowledge on the topics (as they were part of the development team for the product) but I struggle with the "readability" of this book. As an example, each time a concept is introduced, it is done...(read more)

    Read the article

  • Le Sénateur John McCain appelle au renvoi ou à la démission du chef de la NSA, lors d'une interview accordée à Der Spiegel

    Le Sénateur John McCain appelle au renvoi ou à la démission du chef de la NSA, lors d'une interview accordée à Der Spiegel Dans une interview accordé au quotidien allemand Der Spiegel, l'ancien candidat à la présidence le Sénateur John McCain a appelé à la démission du Général Keith Alexander, commandant en chef de la NSA, après les révélations d'une mise sur écoute du chef de l'Etat allemand Angela Merkel. Pour le Sénateur, cette mise sur écoute est une erreur, et il précise même qu'entre...

    Read the article

  • Automating SQL Server Database Deployments: Scripting Details

    To wrap up the series on Database Deployment Challenges, Alexander takes a dive into the details of how he scripted a solution and comes up with several practical tips for getting the most out of any automated database deployment framework. Get your SQL Server database under version control now!Version control is standard for applications, but databases haven’t caught up. So how can you bring database development up to speed? Why should you start? Find out…

    Read the article

  • Xen networking is inconsistent in multiple ways

    - by WildVelociraptor
    I've been running xen for a few weeks now on an Ubuntu 12.04 server. I've got 3 guests: a Windows Server 2003 guest, an Ubuntu guest, and a Windows 7 Guest. My Server 2003 guest seems to work fine; I can ping it from the network, the hostname resolves correctly, and it can see the internet. This guest is attached to xenbr0, and its IP is 10.100.1.21. My Win7 guest is what is driving me crazy. I use the same configuration script as a base, changing the important parts (hostname and boot disk, mainly). It installed correctly, and is currently running, but I am unable to ping this guest. It's hostname is "alexander", with an IP of 10.100.1.22. It is also using xenbr0. The guest can ping the firewall and various IP addressess, but seems unable to resolve hostnames. Now heres the weird part: when I use rdesktop (RDP client) from my laptop (not the xen host) to connect to alexander, it works just fine. It apparently resolves the hostname fine, and does the same with the IP address. So, can someone tell me why I can access this guest using RDP, but not using ping, nslookup, traceroute, etc? It's apparently invisible to all but RDP. Also, is it okay to use two guests on the same bridge, or do i need different ones for each guest? Thanks in advance for any help. Regards

    Read the article

  • How to blacklist a problem Wi-Fi access point by MAC address in Mac OS X

    - by Sam Alexander
    So I am a small Mac-user cog in a larger Windows-based network machine. The network here works fine for most everyone else (on PCs), but I have random timeouts and issues with the Wi-Fi. Luckily, I have identified a few problem access points by MAC address (via their log messages in Console.app). Is it possible to tell my AirPort on my Macbook to avoid those access points, and only speak with the access points who are far less touchy about me drinking the Apple kool-aid? All of the points are on the same network SSID.

    Read the article

  • 6-core Sandy Bridge-E vs. 4-core Ivy Bridge

    - by Alexander Ilyin
    I am currently choosing between Intel Core i7-3770 (quad, Ivy) and Intel Core i7-3930K (6 cores, Sandy Bridge-E). This machine will be used for both work (Adobe, Autodesk software, graphic and coding-related) and gaming. Even if some applications I will use are capable to utilize all 6 cores at once, is it worth preferring Sandy Bridge-E to newer Ivy Bridge? Games aren't and probably will perform better on Ivy, won't they? 6-core is also twice as expensive as a quad Ivy.

    Read the article

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