Search Results

Search found 7583 results on 304 pages for 'roger guess'.

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

  • How to check if a variable is an integer? [closed]

    - by FyrePlanet
    I'm going through my C++ book and have currently made a working Guess The Number game. The game generates a random number based on current time, has the user input their guess, and then tells them whether it was too high, too low, or the correct number. The game functions fine if you enter a number, but returns 'Too High' if you enter something that is not a number (such as a letter or punctuation). Not only does it return 'too high', but it also continually returns it. I was wondering what I could do to check if the guess, as input by the user, is an integer and if it is not, to return 'Not a number. Guess again.' Here is the code. #include <iostream> #include <cstdlib> #include <ctime> using namespace std; int main() { srand(time(0)); // seed the random number generator int theNumber = rand() % 100 + 1; // random number between 1 and 100 int tries = 0, guess; cout << "\tWelcome to Guess My Number!\n\n"; do { cout << "Enter a guess: "; cin >> guess; ++tries; if (guess > theNumber) cout << "Too high!\n\n"; if (guess < theNumber) cout << "Too low!\n\n"; } while (guess != theNumber); cout << "\nThat's it! You got it in " << tries << " guesses!\n"; cout << "\nPress Enter to exit.\n"; cin.ignore(cin.rdbuf()->in_avail() + 1); return 0; }

    Read the article

  • So, I guess I can't use "&&" in the Python if conditional. Any help?

    - by Sergio Tapia
    Here's my code: # F. front_back # Consider dividing a string into two halves. # If the length is even, the front and back halves are the same length. # If the length is odd, we'll say that the extra char goes in the front half. # e.g. 'abcde', the front half is 'abc', the back half 'de'. # Given 2 strings, a and b, return a string of the form # a-front + b-front + a-back + b-back def front_back(a, b): # +++your code here+++ if len(a) % 2 == 0 && len(b) % 2 == 0: return a[:(len(a)/2)] + b[:(len(b)/2)] + a[(len(a)/2):] + b[(len(b)/2):] else: #todo! Not yet done. :P return I'm getting an error in the IF conditional. What am I doing wrong?

    Read the article

  • Unable to install bin files.(No such file or directory error)

    - by rogerstone
    I wanted to install adobe reader on my ubuntu 10.10(Maverick Meerkat).I have downloaded the file and copied it on my desktop.I had then browsed to the desktop directory through command line terminal. I had tried all the possible combinations of the commands but still i get a "file or directory does not exist error" roger@ubuntu:~/Desktop$ chmod a+x AdbeRdr9.4-1_i486linux_enu.bin roger@ubuntu:~/Desktop$ sudo ./AdbeRdr9.4-1_i486linux_enu.bin sudo: unable to execute ./AdbeRdr9.4-1_i486linux_enu.bin: No such file or directory I tried without the sudo and this is what i get roger@ubuntu:~/Desktop$ chmod a+x AdbeRdr9.4-1_i486linux_enu.bin roger@ubuntu:~/Desktop$ ./AdbeRdr9.4-1_i486linux_enu.bin bash: ./AdbeRdr9.4-1_i486linux_enu.bin: No such file or directory The file is present in the desktop.Where am i going wrong? P.S:This is not a duplicate of the question Cannot install .bin package on Ubuntu

    Read the article

  • How do I make my applet turn the user's input into an integer and compare it to the computer's random number?

    - by Kitteran
    I'm in beginning programming and I don't fully understand applets yet. However, (with some help from internet tutorials) I was able to create an applet that plays a game of guess with the user. The applet compiles fine, but when it runs, this error message appears: "Exception in thread "main" java.lang.NumberFormatException: For input string: "" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) at java.lang.Integer.parseInt(Integer.java:470) at java.lang.Integer.parseInt(Integer.java:499) at Guess.createUserInterface(Guess.java:101) at Guess.<init>(Guess.java:31) at Guess.main(Guess.java:129)" I've tried moving the "userguess = Integer.parseInt( t1.getText() );" on line 101 to multiple places, but I still get the same error. Can anyone tell me what I'm doing wrong? The Code: // Creates the game GUI. import javax.swing.*; import java.awt.*; import java.awt.event.*; public class Guess extends JFrame{ private JLabel userinputJLabel; private JLabel lowerboundsJLabel; private JLabel upperboundsJLabel; private JLabel computertalkJLabel; private JButton guessJButton; private JPanel guessJPanel; static int computernum; int userguess; static void declare() { computernum = (int) (100 * Math.random()) + 1; //random number picked (1-100) } // no-argument constructor public Guess() { createUserInterface(); } // create and position GUI components private void createUserInterface() { // get content pane and set its layout Container contentPane = getContentPane(); contentPane.setLayout( null ); contentPane.setBackground( Color.white ); // set up userinputJLabel userinputJLabel = new JLabel(); userinputJLabel.setText( "Enter Guess Here -->" ); userinputJLabel.setBounds( 0, 65, 120, 50 ); userinputJLabel.setHorizontalAlignment( JLabel.CENTER ); userinputJLabel.setBackground( Color.white ); userinputJLabel.setOpaque( true ); contentPane.add( userinputJLabel ); // set up lowerboundsJLabel lowerboundsJLabel = new JLabel(); lowerboundsJLabel.setText( "Lower Bounds Of Guess = 1" ); lowerboundsJLabel.setBounds( 0, 0, 170, 50 ); lowerboundsJLabel.setHorizontalAlignment( JLabel.CENTER ); lowerboundsJLabel.setBackground( Color.white ); lowerboundsJLabel.setOpaque( true ); contentPane.add( lowerboundsJLabel ); // set up upperboundsJLabel upperboundsJLabel = new JLabel(); upperboundsJLabel.setText( "Upper Bounds Of Guess = 100" ); upperboundsJLabel.setBounds( 250, 0, 170, 50 ); upperboundsJLabel.setHorizontalAlignment( JLabel.CENTER ); upperboundsJLabel.setBackground( Color.white ); upperboundsJLabel.setOpaque( true ); contentPane.add( upperboundsJLabel ); // set up computertalkJLabel computertalkJLabel = new JLabel(); computertalkJLabel.setText( "Computer Says:" ); computertalkJLabel.setBounds( 0, 130, 100, 50 ); //format (x, y, width, height) computertalkJLabel.setHorizontalAlignment( JLabel.CENTER ); computertalkJLabel.setBackground( Color.white ); computertalkJLabel.setOpaque( true ); contentPane.add( computertalkJLabel ); //Set up guess jbutton guessJButton = new JButton(); guessJButton.setText( "Enter" ); guessJButton.setBounds( 250, 78, 100, 30 ); contentPane.add( guessJButton ); guessJButton.addActionListener( new ActionListener() // anonymous inner class { // event handler called when Guess button is pressed public void actionPerformed( ActionEvent event ) { guessActionPerformed( event ); } } // end anonymous inner class ); // end call to addActionListener // set properties of application's window setTitle( "Guess Game" ); // set title bar text setSize( 500, 500 ); // set window size setVisible( true ); // display window //create text field TextField t1 = new TextField(); // Blank text field for user input t1.setBounds( 135, 78, 100, 30 ); contentPane.add( t1 ); userguess = Integer.parseInt( t1.getText() ); //create section for computertalk Label computertalkLabel = new Label(""); computertalkLabel.setBounds( 115, 130, 300, 50); contentPane.add( computertalkLabel ); } // Display computer reactions to user guess private void guessActionPerformed( ActionEvent event ) { if (userguess > computernum) //if statements (computer's reactions to user guess) computertalkJLabel.setText( "Computer Says: Too High" ); else if (userguess < computernum) computertalkJLabel.setText( "Computer Says: Too Low" ); else if (userguess == computernum) computertalkJLabel.setText( "Computer Says:You Win!" ); else computertalkJLabel.setText( "Computer Says: Error" ); } // end method oneJButtonActionPerformed // end method createUserInterface // main method public static void main( String args[] ) { Guess application = new Guess(); application.setDefaultCloseOperation (JFrame.EXIT_ON_CLOSE); } // end method main } // end class Phone

    Read the article

  • PHP won't echo out the $_POST ...

    - by user296516
    Hi guys, got a small problem, this code echo '<input name="textfield" type="text" id="textfield" value="Roger" />'; echo 'Hello, '.$_POST['textfield'].'<br>'; should echo out "Hello, Roger", as roger is the default value, yet it gives out only "Hello, " and nothing else. Any suggestions? Thanks!

    Read the article

  • Problem running a Python program, error: Name 's' is not defined.

    - by Sergio Tapia
    Here's my code: #This is a game to guess a random number. import random guessTaken = 0 print("Hello! What's your name kid") myName = input() number = random.randint(1,20) print("Well, " + myName + ", I'm thinking of a number between 1 and 20.") while guessTaken < 6: print("Take a guess.") guess = input() guess = int(guess) guessTaken = guessTaken + 1 if guess < number: print("You guessed a little bit too low.") if guess > number: print("You guessed a little too high.") if guess == number: break if guess == number: guessTaken = str(guessTaken) print("Well done " + myName + "! You guessed the number in " + guessTaken + " guesses!") if guess != number: number = str(number) print("No dice kid. I was thinking of this number: " + number) This is the error I get: Name error: Name 's' is not defined. I think the problem may be that I have Python 3 installed, but the program is being interpreted by Python 2.6. I'm using Linux Mint if that can help you guys help me. Using Geany as the IDE and pressing F5 to test it. It may be loading 2.6 by default, but I don't really know. :( Edit: Error 1 is: File "GuessingGame.py", line 8, in <Module> myName = input() Error 2 is: File <string>, line 1, in <Module>

    Read the article

  • The perverse hangman problem

    - by Shalmanese
    Perverse Hangman is a game played much like regular Hangman with one important difference: The winning word is determined dynamically by the house depending on what letters have been guessed. For example, say you have the board _ A I L and 12 remaining guesses. Because there are 13 different words ending in AIL (bail, fail, hail, jail, kail, mail, nail, pail, rail, sail, tail, vail, wail) the house is guaranteed to win because no matter what 12 letters you guess, the house will claim the chosen word was the one you didn't guess. However, if the board was _ I L M, you have cornered the house as FILM is the only word that ends in ILM. The challenge is: Given a dictionary, a word length & the number of allowed guesses, come up with an algorithm that either: a) proves that the player always wins by outputting a decision tree for the player that corners the house no matter what b) proves the house always wins by outputting a decision tree for the house that allows the house to escape no matter what. As a toy example, consider the dictionary: bat bar car If you are allowed 3 wrong guesses, the player wins with the following tree: Guess B NO -> Guess C, Guess A, Guess R, WIN YES-> Guess T NO -> Guess A, Guess R, WIN YES-> Guess A, WIN

    Read the article

  • Visualising data a different way with Pivot collections

    - by Rob Farley
    Roger’s been doing a great job extending PivotViewer recently, and you can find the list of LobsterPot pivots at http://pivot.lobsterpot.com.au Many months back, the TED Talk that Gary Flake did about Pivot caught my imagination, and I did some research into it. At the time, most of what we did with Pivot was geared towards what we could do for clients, including making Pivot collections based on students at a school, and using it to browse PDF invoices by their various properties. We had actual commercial work based on Pivot collections back then, and it was all kinds of fun. Later, we made some collections for events that were happening, and even got featured in the TechEd Australia keynote. But I’m getting ahead of myself... let me explain the concept. A Pivot collection is an XML file (with .cxml extension) which lists Items, each linking to an image that’s stored in a Deep Zoom format (this means that it contains tiles like Bing Maps, so that the browser can request only the ones of interest according to the zoom level). This collection can be shown in a Silverlight application that uses the PivotViewer control, or in the Pivot Browser that’s available from getpivot.com. Filtering and sorting the items according to their facets (attributes, such as size, age, category, etc), the PivotViewer rearranges the way that these are shown in a very dynamic way. To quote Gary Flake, this lets us “see patterns which are otherwise hidden”. This browsing mechanism is very suited to a number of different methods, because it’s just that – browsing. It’s not searching, it’s more akin to window-shopping than doing an internet search. When we decided to put something together for the conferences such as TechEd Australia 2010 and the PASS Summit 2010, we did some screen-scraping to provide a different view of data that was already available online. Nick Hodge and Michael Kordahi from Microsoft liked the idea a lot, and after a bit of tweaking, we produced one that Michael used in the TechEd Australia keynote to show the variety of talks on offer. It’s interesting to see a pattern in this data: The Office track has the most sessions, but if the Interactive Sessions and Instructor-Led Labs are removed, it drops down to only the sixth most popular track, with Cloud Computing taking over. This is something which just isn’t obvious when you look an ordinary search tool. You get a much better feel for the data when moving around it like this. The more observant amongst you will have noticed some difference in the collection that Michael is demonstrating in the picture above with the screenshots I’ve shown. That’s because it’s been extended some more. At the SQLBits conference in the UK this year, I had some interesting discussions with the guys from Xpert360, particularly Phil Carter, who I’d met in 2009 at an earlier SQLBits conference. They had got around to producing a Pivot collection based on the SQLBits data, which we had been planning to do but ran out of time. We discussed some of ways that Pivot could be used, including the ways that my old friend Howard Dierking had extended it for the MSDN Magazine. I’m not suggesting I influenced Xpert360 at all, but they certainly inspired us with some of their posts on the matter So with LobsterPot guys David Gardiner and Roger Noble both having dabbled in Pivot collections (and Dave doing some for clients), I set Roger to work on extending it some more. He’s used various events and so on to be able to make an environment that allows us to do quick deployment of new collections, as well as showing the data in a grid view which behaves as if it were simply a third view of the data (the other two being the array of images and the ‘histogram’ view). I see PivotViewer as being a significant step in data visualisation – so much so that I feature it when I deliver talks on Spatial Data Visualisation methods. Any time when there is information that can be conveyed through an image, you have to ask yourself how best to show that image, and whether that image is the focal point. For Spatial data, the image is most often a map, and the map becomes the central mode for navigation. I show Pivot with postcode areas, since I can browse the postcodes based on their data, and many of the images are recognisable (to locals of South Australia). Naturally, the images could link through to the map itself, and so on, but generally people think of Spatial data in terms of navigating a map, which doesn’t always gel with the information you’re trying to extract. Roger’s even looking into ways to hook PivotViewer into the Bing Maps API, in a similar way to the Deep Earth project, displaying different levels of map detail according to how ‘zoomed in’ the images are. Some of the work that Dave did with one of the schools was generating the Deep Zoom tiles “on the fly”, based on images stored in a database, and Roger has produced a collection which uses images from flickr, that lets you move from one search term to another. Pulling the images down from flickr.com isn’t particularly ideal from a performance aspect, and flickr doesn’t store images in a small-enough format to really lend itself to this use, but you might agree that it’s an interesting concept which compares nicely to using Maps. I’m looking forward to future versions of the PivotViewer control, and hope they provide many more events that can be used, and even more hooks into it. Naturally, LobsterPot could help provide your business with a PivotViewer experience, but you can probably do a lot of it yourself too. There’s a thorough guide at getpivot.com, which is how we got into it. For some examples of what we’ve done, have a look at http://pivot.lobsterpot.com.au. I’d like to see PivotViewer really catch on a data visualisation tool.

    Read the article

  • The Future of Life Assurance Conference Recap

    - by [email protected]
    I recently wrote about the Life Insurance Conference held in Washington, DC last month. This week I was both an attendee and guest speaker the 13th Annual Future of Life Assurance Conference held at The Guoman Tower in London, UK. It's amazing that these two conferences were held on opposition sides of the Atlantic Ocean and addressed many of the same session topics and themes. Insurance is certainly a global industry! This year's conference was attended by many of the leading carriers and CEOs in the UK and across Europe.The sessions included a strong lineup of keynote speakers and panel discussions from carriers such as Legal & General, Skandia, Aviva, Standard Life, Friends Provident, LV=, Zurich UK, Barclays and Scottish Life. Sessions topics addressed a variety of business and regulatory issues including: Ensuring a profitable future Key priorities in regulation The future of advice The impact of the RDR on distribution Bancassurance Gaining control of the customer relationship Revitalizing product offerings In addition, Oracle speakers (Glenn Lottering and myself) led specific sessions on gearing up for Solvency II and speeding product development through adaptive rules-based systems. The main themes that played throughout many of the sessions included: change is here, focusing on customers, the current economic crisis has been challenging and the industry needs to get back to the basics and simplify - simplify - simplify. Additionally, it is clear that the UK Life & Pension markets will be going through some major changes as new RDR regulation related to advisor fees and commission and automatic enrollment are rolled out in 2012 Roger A.Soppe, CLU, LUTCF, is the Senior Director of Insurance Strategy, Oracle Insurance.

    Read the article

  • Persuading openldap to work with SSL on Ubuntu with cn=config

    - by Roger
    I simply cannot get this (TLS connection to openldap) to work and would appreciate some assistance. I have a working openldap server on ubuntu 10.04 LTS, it is configured to use cn=config and most of the info I can find for TLS seems to use the older slapd.conf file :-( I've been largely following the instructions here https://help.ubuntu.com/10.04/serverguide/C/openldap-server.html plus stuff I've read here and elsewhere - which of course could be part of the problem as I don't totally understand all of this yet! I have created an ssl.ldif file as follows; dn:cn=config add: olcTLSCipherSuite olcTLSCipherSuite: TLSV1+RSA:!NULL add: olcTLSCRLCheck olcTLSCRLCheck: none add: olcTLSVerifyClient olcTLSVerifyClient: never add: olcTLSCACertificateFile olcTLSCACertificateFile: /etc/ssl/certs/ldap_cacert.pem add: olcTLSCertificateFile olcTLSCertificateFile: /etc/ssl/certs/my.domain.com_slapd_cert.pem add: olcTLSCertificateKeyFile olcTLSCertificateKeyFile: /etc/ssl/private/my.domain.com_slapd_key.pem and I import it using the following command line ldapmodify -x -D cn=admin,dc=mydomain,dc=com -W -f ssl.ldif I have edited /etc/default/slapd so that it has the following services line; SLAPD_SERVICES="ldap:/// ldapi:/// ldaps:///" And everytime I'm making a change, I'm restarting slapd with /etc/init.d/slapd restart The following command line to test out the non TLS connection works fine; ldapsearch -d 9 -D cn=admin,dc=mydomain,dc=com -w mypassword \ -b dc=mydomain,dc=com -H "ldap://mydomain.com" "cn=roger*" But when I switch to ldaps using this command line; ldapsearch -d 9 -D cn=admin,dc=mydomain,dc=com -w mypassword \ -b dc=mydomain,dc=com -H "ldaps://mydomain.com" "cn=roger*" This is what I get; ldap_url_parse_ext(ldaps://mydomain.com) ldap_create ldap_url_parse_ext(ldaps://mydomain.com:636/??base) ldap_sasl_bind ldap_send_initial_request ldap_new_connection 1 1 0 ldap_int_open_connection ldap_connect_to_host: TCP mydomain.com:636 ldap_new_socket: 3 ldap_prepare_socket: 3 ldap_connect_to_host: Trying 127.0.0.1:636 ldap_pvt_connect: fd: 3 tm: -1 async: 0 TLS: can't connect: A TLS packet with unexpected length was received.. ldap_err2string ldap_sasl_bind(SIMPLE): Can't contact LDAP server (-1) Now if I check netstat -al I can see; tcp 0 0 *:www *:* LISTEN tcp 0 0 *:ssh *:* LISTEN tcp 0 0 *:https *:* LISTEN tcp 0 0 *:ldaps *:* LISTEN tcp 0 0 *:ldap *:* LISTEN I'm not sure if this is significant as well ... I suspect it is; openssl s_client -connect mydomain.com:636 -showcerts CONNECTED(00000003) 916:error:140790E5:SSL routines:SSL23_WRITE:ssl handshake failure:s23_lib.c:188: I think I've made all my certificates etc OK and here are the results of some checks; If I do this; certtool -e --infile /etc/ssl/certs/ldap_cacert.pem I get Chain verification output: Verified. certtool -e --infile /etc/ssl/certs/mydomain.com_slapd_cert.pem Gives "certtool: the last certificate is not self signed" but it otherwise seems OK? Where have I gone wrong? Surely getting openldap to run securely on ubuntu should be easy and not require a degree in rocket science! Any ideas?

    Read the article

  • Beginner python - stuck in a loop

    - by Jeremy
    I have two begininer programs, both using the 'while' function, one works correctly, and the other gets me stuck in a loop. The first program is this; num=54 bob = True print('The guess a number Game!') while bob == True: guess = int(input('What is your guess? ')) if guess==num: print('wow! You\'re awesome!') print('but don\'t worry, you still suck') bob = False elif guess>num: print('try a lower number') else: print('close, but too low') print('game over')`` and it gives the predictable output of; The guess a number Game! What is your guess? 12 close, but too low What is your guess? 56 try a lower number What is your guess? 54 wow! You're awesome! but don't worry, you still suck game over However, I also have this program, which doesn't work; #define vars a = int(input('Please insert a number: ')) b = int(input('Please insert a second number: ')) #try a function def func_tim(a,b): bob = True while bob == True: if a == b: print('nice and equal') bob = False elif b > a: print('b is picking on a!') else: print('a is picking on b!') #call a function func_tim(a,b) Which outputs; Please insert a number: 12 Please insert a second number: 14 b is picking on a! b is picking on a! b is picking on a! ...(repeat in a loop).... Can someone please let me know why these programs are different? Thank you!

    Read the article

  • What should you do differently when designing websites for an embedded web server

    - by Roger Attrill
    When designing a website to be accessed from an embedded webserver such as KLone, what do you need to do differently compared to a 'standard' web server. I'm talking about considerations at the front end design stage, before the actual building and coding up. For example, typically in such situations, memory size is a premium, so I guess larger images are out, and maybe more attention should be focused on achieving a good look and feel using CSS/Javascript rather than bitmap images.

    Read the article

  • Setting an instanced class property overwrites the property in all instances.

    - by Peter Moore
    I have two instances of a class. Setting a property in the first instance will set it for the second instance too. Why? It shouldn't. The property is not a "prototype property". Check the code below, what happens to Peter Griffin? Two objects are created and given the name "Peter Griffin" and "Roger Moore" but the alert boxes will say "Peter Moore" and "Roger Moore". What happened to Peter Griffin? var BaseClass = function(){ this.name = ""; this.data = {}; this.data.lastname = ""; } var ExtendedClass = function(){ this.setName = function(fname, lname){ this.name = fname; this.data.lastname = lname; } this.hello = function(){ alert("Full name: " + this.name + " " + this.data.lastname); } } ExtendedClass.prototype = new BaseClass(); pilot = new ExtendedClass(); driver = new ExtendedClass(); pilot.setName("Peter", "Griffin"); driver.setName("Roger", "Moore"); pilot.hello(); // Full name: Peter Moore driver.hello(); // Full name: Roger Moore

    Read the article

  • So, I guess I can't use "&&" in the Python if conditional. What should I use in this case? Any help?

    - by Sergio Tapia
    Here's my code: # F. front_back # Consider dividing a string into two halves. # If the length is even, the front and back halves are the same length. # If the length is odd, we'll say that the extra char goes in the front half. # e.g. 'abcde', the front half is 'abc', the back half 'de'. # Given 2 strings, a and b, return a string of the form # a-front + b-front + a-back + b-back def front_back(a, b): # +++your code here+++ if len(a) % 2 == 0 && len(b) % 2 == 0: return a[:(len(a)/2)] + b[:(len(b)/2)] + a[(len(a)/2):] + b[(len(b)/2):] else: #todo! Not yet done. :P return I'm getting an error in the IF conditional. What am I doing wrong? Edit: I meant no arrogance here. Someone edited my question title to make it sound douchy. I was genuinely confused about what to use, didn't think 'and' would be a keyword. Please don't downvote as other newbies might be confused about it as well.

    Read the article

  • Advanced SQL Data Compare throught multiple tables

    - by podosta
    Hello, Consider the situation below. Two tables (A & B), in two environments (DEV & TEST), with records in those tables. If you look the content of the tables, you understand that functionnal data are identical. I mean except the PK and FK values, the name Roger is sill connected to Fruit & Vegetable. In DEV environment : Table A 1 Roger 2 Kevin Table B (italic field is FK to table A) 1 1 Fruit 2 1 Vegetable 3 2 Meat In TEST environment : Table A 4 Roger 5 Kevin Table B (italic field is FK to table A) 7 4 Fruit 8 4 Vegetable 9 5 Meat I'm looking for a SQL Data Compare tool which will tell me there is no difference in the above case. Or if there is, it will generate insert & update scripts with the right order (insert first in A then B) Thanks a lot guys, Grégoire

    Read the article

  • Making a full-screen animation on Android? Should I use OPENGL?

    - by Roger Travis
    Say I need to make several full-screen animation that would consist of about 500+ frames each, similar to the TalkingTom app ( https://play.google.com/store/apps/details?id=com.outfit7.talkingtom2free ). Animation should be playing at a reasonable speed - supposedly not less, then 20fps - and pictures should be of a reasonable quality, not overly compressed. What method do you think should I use? So far I tried: storing each frame as a compressed JPEG before animation starts, loading each frame into a byteArray as the animation plays, decode corresponding byteArray into a bitmap and draw it on a surface view. Problem - speed is too low, usually about 5-10 FPS. I have thought of two other options. turning all animations into one movie file... but I guess there might be problems with starting, pausing and seeking to the exactly right frame... what do you think? another option I thought about was using OPENGL ( while I never worked with it before ), to play animation frame by frame. What do you think, would opengl be able to handle it? Thanks!

    Read the article

  • Pub banter - content strategy at the ballot box?

    - by Roger Hart
    Last night, I was challenged to explain (and defend) content strategy. Three sheets to the wind after a pub quiz, this is no simple task, but I hope I acquitted myself passably. I say "hope" because there was a really interesting question I couldn't answer to my own satisfaction. I wonder if any of you folks out there in the ethereal internet hive-mind can help me out? A friend - a rather concrete thinker who mathematically models complex biological systems for a living - pointed out that my examples were largely routed in business-to-business web sales and support. He challenged me with: Say you've got a political website, so your goal is to have somebody read it and vote for you - how do you measure the effectiveness of that content? Well, you would. umm. Oh dear. I guess what we're talking about here, to yank it back to my present comfort zone, is a sales process where your point of conversion is off the site. The political example is perhaps a little below the belt, since what you can and can't do, and what data you can and can't collect is so restricted. You can't throw up a "How did you hear about this election?" questionnaire in the polling booth. Exit polls don't pull in your browsing history and site session information. Not everyone fatuously tweets and geo-tags each moment of their lives. Oh, and folks lie. The business example might be easier to attack. You could have, say, a site for a farm shop that only did over the counter sales. Either way, it's tricky. I fell back on some of the work I've done usability testing and benchmarking documentation, and suggested similar, quick and dirty, small sample qualitative UX trials. I'm not wholly sure that was right. Any thoughts? How might we measure and curate for this kind of discontinuous conversion?

    Read the article

  • Windows Phone 7: Using Pinch Gestures For Pinch and As A Secondary Drag Gesture

    - by Roger Guess
    I am using the drag gesture to move elements on a canvas. I am using the pinch gesture to zoom/tranlate the size of the canvas. What I want to do now is move the entire canvas based on the movement of both fingers in a pinch. I know I can do this with the move, but I need that for items on the canvas itself, and sometimes the entire canvas is covered with items that would make it so you could not select the canvas to move it. Is this possible with the PinchGestureEventArgs?

    Read the article

  • Value Chain Planning in Las Vegas

    - by Paul Homchick
    Several Oracle Value Chain Planning experts will be presenting at the Mandalay Bay Convention Center in Las Vegas, for Collaborate 2010- April 18th- 22nd, 2010. We have five sessions as follows: Monday, April 19, 1:15 pm - 2:15 pm, Breakers H, Roger Goossens VCP Vice President Leveraging Oracle Value Chain Planning for Your Planning Business Transformation Monday, April 19th, 2010- 1.15 pm-2.15 pm, Breakers D, Rich Caballero, CRM Vice President Delivering Superior Customer Service with Oracle's Siebel Service Applications Wednesday, April 21, 2:15 pm - 3:15 pm, Mandalay Bay Ballroom A, Roger Goossens VCP Vice President Value Chain Planning for JD Edwards EnterpriseOne We will also be in the demogrounds, so stop by to see the latest VCP innovations from Oracle and talk to our experts.

    Read the article

  • Value Chain Planning in Las Vegas

    - by Paul Homchick
    Several Oracle Value Chain Planning experts will be presenting at the Mandalay Bay Convention Center in Las Vegas, for Collaborate 2010- April 18th- 22nd, 2010. We have five sessions as follows: Monday, April 19, 1:15 pm - 2:15 pm, Breakers H, Roger Goossens Oracle VCP Vice President Leveraging Oracle Value Chain Planning for Your Planning Business Transformation Monday, April 19, 3:45 pm - 4:45 pm, Breakers I, Scott Malcolm, Oracle VCP Development Complex Supply Chain Planning Made Easy: Introducing Oracle Rapid Planning Tuesday, April 20, 2:00 pm - 3:00 pm, Breakers I, John Bermudez, Oracle VCP Strategy Synchronize Your Financial and Operating Plans with Oracle Integrated Business Planning Wednesday, April 21, 10:30 am - 11:30 am, Breakers I, Vikash Goyal, Oracle VCP Strategy Oracle Demantra: What's New? Wednesday, April 21, 2:15 pm - 3:15 pm, Mandalay Bay Ballroom A, Roger Goossens Oracle VCP Vice President Value Chain Planning for JD Edwards EnterpriseOne We will also be in the demogrounds, so stop by to see the latest VCP innovations from Oracle and talk to our experts.

    Read the article

  • Ad-hoc taxonomy: owning the chess set doesn't mean you decide how the little horsey moves

    - by Roger Hart
    There was one of those little laugh-or-cry moments recently when I heard an anecdote about content strategy failings at a major online retailer. The story goes a bit like this: successful company in a highly commoditized marketplace succeeds on price and largely ignores its content team. Being relatively entrepreneurial, the founders are still knocking around, and occasionally like to "take an interest". One day, they decree that clothing sold on the site can no longer be described as "unisex", because this sounds old fashioned. Sad now. Let me just reiterate for the folks at the back: large retailer, commoditized market place, differentiating on price. That's inherently unstable. Sooner or later, they're going to need one or both of competitive differentiation and significant optimization. I can't speak for the latter, since I'm hypothesizing off a raft of rumour, but one of the simpler paths to the former is to become - or rather acknowledge that they are - a content business. Regardless, they need highly-searchable terminology. Even in the face of tooth and claw resistance to noticing the fundamental position content occupies in driving sales (and SEO) on the web, there's a clear information problem here. Dilettante taxonomy is a disaster. Ok, so this is a small example, but that kind of makes it a good one. Unisex probably is the best way of describing clothing designed to suit either men or women interchangeably. It certainly takes less time to type (and read). It's established terminology, and as a single word, it's significantly better for web readability than a phrasal workaround. Something like "fits men or women" is short, by could fall foul of clause-level discard in web scanning. It's not an adjective, so for intuitive reading it's never going to be near the start of a title or description. It would also clutter up search results, and impose cognitive load in list scanning. Sorry kids, it's just worse. Even if "unisex" were an archaism (which it isn't), the only thing that would weigh against its being more usable and concise terminology would be evidence that this archaism were hurting conversions. Good luck with that. We once - briefly - called one of our products a "Can of worms". It was a bundle in a bug-tracking suite, and we thought it sounded terribly cool. Guess how well that sold. We have information and content professionals for a reason: to make sure that whatever we put in front of users is optimised to meet user and business goals. If that thinking doesn't inform style guides, taxonomy, messaging, title structure, and so forth, you might as well be finger painting.

    Read the article

  • Strange links appearing in 404 logs

    - by MJWadmin
    I've recently been going through our 404 logs and we have a number of urls which look like this turning up:- http://www.makejusticework.org.uk/%2B%255BPLM=0%255D%2BGET%2Bhttp:/www.makejusticework.org.uk/%2B%255B0,51217,54078%255D%2B-%253E%2B%255BN%255D%2BPOST%2Bhttp:/www.makejusticework.org.uk/media/roma-hoopers-justice-campaign-blog/prison-expensive-making-people-worse-roger-graef-obe-ceo-films-record-ambassador-justice-work/2012/02/22/%2B%255B0,0,67227%255D It contains the actual url, which is:- http://www.makejusticework.org.uk/media/roma-hoopers-justice-campaign-blog/prison-expensive-making-people-worse-roger-graef-obe-ceo-films-record-ambassador-justice-work/2012/02/22/ This blog post relates to a recently redirected url (standard redirect 301) hence the concern - can anyone shed any light on this kind of thing?

    Read the article

  • Windows Phone 8, possible tablets and what the latest update might mean

    - by Roger Hart
    Microsoft have just announced an update to Windows Phone 8. As one of the five, maybe six people who actually bought a WP8 handset I found this interesting. Then I read the blog post about it, and rushed off to write somewhat less than a thousand words about a single picture. The blog post announces an extra column of tiles on the start screen, and support for higher resolutions. If we ignore all the usual flummery about how this will make your life better, that (and the rotation lock) sounds a little like stage setting for tablets. Looking at the preview screenshot, I started to wonder. What it’s called Phablet_5F00_StartScreenProductivity_5F00_01_5F00_072A1240.jpg Pretty conclusive. If you can brand something a “phablet” and sleep at night you’re made of sterner stuff than I am, but that’s beside the point. It’s explicit in the post that Microsoft are expecting a broader range of form factors for WP8, but they stop short of quite calling out tablet size. The extra columns and resolution definitely back that up, so why stop at a 6 inch “phablet”? Sadly, the string of numbers there don’t really look like a Lumia model number – that would be a bit tendentious even for a speculative blog post about a single screenshot. “Productivity” is interesting too. I get into this a bit more below, but this is a pretty clear pitch for a business device. What it looks like Something that would look quite decent on a 7 inch screen, but something a bit too vertical to go toe-to-toe with the Surface. Certainly, it would look a lot better on a large-factor phone than any of the current models. Those tiles are going to get cramped and a bit ugly if the handsets aren’t getting bigger. What’s on it You have a bunch of missed calls, you rarely text, use a stocks app, and your budget spreadsheet and meeting notes are a thumb-reach away. Outlook is your main form of email. You care enough about LinkedIn to not only install its app but give it a huge live tile. There’s no beating about the bush here, the implicit persona is a corporate exec. With Nokia in the bag and Blackberry pushing daisies, that may not be a stupid play. There’s almost certainly a niche there if they can parlay their corporate credentials into filling it before BYOD (which functionally means an iPhone) reaches the late adopters. The really quite slick WP8 Office implementation ought to help here. This is the face they’ve chosen to present, the cultural milieu they’re normalizing for Windows Phone. It’s an iPhone for Serious Business Grown-ups. Could work, I guess. Does it mean anything? Is the latest WP8 update a sign that we can expect to see tablets running Windows Phone rather than WinRT? Well, WinRT tablets haven’t exactly taken off but I’m not quite going to make a leap like that just from a file name and a column of icons. I feel pretty safe, however, conjecturing that Microsoft would like to squeeze a WP8 “phablet” into the palm of every exec who’s ever grumbled about their Blackberry, and this release might get them a bit closer. If it works well incrementing up to larger devices, then that could be a fair hedge against WinRt crashing and burning any harder in the marketplace.

    Read the article

  • What's wrong with my logic (Java syntax)

    - by soda
    I'm trying to make a simple program that picks a random number and takes input from the user. The program should tell the user if the guess was hot (-/+ 5 units) or cold, but I never reach the else condition. Here's the section of code: public static void giveHint (int guess) { int min = guess - 5; int max = guess + 5; if ((guess > min) && (guess < max)) { System.out.println("Hot.."); } else { System.out.println("Cold.."); } }

    Read the article

  • How do I implement an higher lower game algorithm?

    - by lazorde
    The computer will guess a player’s number between 1 and 100. After each guess the human player should respond “higher”, “lower” or “correct”. Your program should be able to guess the player’s number in no more than 7 tries. Begin by explaining the game to the player, telling him/her to think of a number between 1 and 100. Make the computer do what you would normally do to guess a number in a certain range. Allow the user to respond with “higher”, “lower”, or “correct” after each computer guess. Output the number of tries it took the computer to guess the number. Make the game as user friendly as you can.

    Read the article

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