Daily Archives

Articles indexed Tuesday March 1 2011

Page 9/10 | < Previous Page | 5 6 7 8 9 10  | Next Page >

  • Getting started as a programmer -- school or self-study?

    - by Cyberherbalist
    My son who has is married with two small children has decided that he needs a change of career, and is considering getting into programming. He would do well in the field, I am certain, but I am uncertain how to advise him with regards to a lengthy course of schooling, or just try to learn 'on the job", so to speak. I suspect that if he doesn't ultimately get at least an associate degree in program (like his old man), that his job possibilities are going to be very constrained. This isn't the Dot-Com Bubble, after all, when they'd hire you if you could spell c-o-m-p-u-t-e-r because they needed bodies and the ability to fog a mirror wasn't quite enough. Should he go for a full program at the university, a two-year program (he already has a 2-year degree in video production, so he's got the general ed requirements whipped), or does anyone think self-study alone might be enough? To get started, anyway. I started back in 1987 with COBOL and a 2-year degree, which seemed the minimum at the time, but perhaps things are different now?

    Read the article

  • What is the philosophy/reasoning behind C#'s Pascal-casing method names?

    - by Nocturne
    I'm just starting to learn C#. Coming from a background in Java, C++ and Objective-C, I find C#'s Pascal-casing its method-names rather unique, and a tad difficult to get used to at first. What is the reasoning and philosophy behind this? I'm guessing it is because of C# properties. Unlike in Objective-C, where method names can be exactly the same as an instance variables, this is not the case with C#. I would guess one of the goals with properties (as it is with most of the languages that support it) is to make properties truly indistinguishable from variables and methods. So, one can have an "int x" in C#, and the corresponding property becomes X. To ensure that properties and methods are indistinguishable, all method names I'm guessing are also therefore expected to start with an uppercase letter. (This is just my hypothesis based on what I know of C# so far—I'm still learning). I'm very curious to know how this curious guideline came into being (given that it's not something one sees in most other languages where method names are expected to start with a lowercase letter) (EDIT: By Pascal-casing, I mean PascalCase (which is basically camelCase but starting with a capital letter). Method names typically start with a lowercase letter in most languages)

    Read the article

  • "Imprinting" as a language feature?

    - by MKO
    Idea I had this idea for a language feature that I think would be useful, does anyone know of a language that implements something like this? The idea is that besides inheritance a class can also use something called "imprinting" (for lack of better term). A class can imprint one or several (non-abstract) classes. When a class imprints another class it gets all it's properties and all it's methods. It's like the class storing an instance of the imprinted class and redirecting it's methods/properties to it. A class that imprints another class therefore by definition also implements all it's interfaces and it's abstract class. So what's the point? Well, inheritance and polymorphism is hard to get right. Often composition gives far more flexibility. Multiple inheritance offers a slew of different problems without much benefits (IMO). I often write adapter classes (in C#) by implementing some interface and passing along the actual methods/properties to an encapsulated object. The downside to that approach is that if the interface changes the class breaks. You also you have to put in a lot of code that does nothing but pass things along to the encapsulated object. A classic example is that you have some class that implements IEnumerable or IList and contains an internal class it uses. With this technique things would be much easier Example (c#) [imprint List<Person> as peopleList] public class People : PersonBase { public void SomeMethod() { DoSomething(this.Count); //Count is from List } } //Now People can be treated as an List<Person> People people = new People(); foreach(Person person in people) { ... } peopleList is an alias/variablename (of your choice)used internally to alias the instance but can be skipped if not needed. One thing that's useful is to override an imprinted method, that could be achieved with the ordinary override syntax public override void Add(Person person) { DoSomething(); personList.Add(person); } note that the above is functional equivalent (and could be rewritten by the compiler) to: public class People : PersonBase , IList<Person> { private List<Person> personList = new List<Person>(); public override void Add(object obj) { this.personList.Add(obj) } public override int IndexOf(object obj) { return personList.IndexOf(obj) } //etc etc for each signature in the interface } only if IList changes your class will break. IList won't change but an interface that you, someone in your team, or a thirdparty has designed might just change. Also this saves you writing a whole lot of code for some interfaces/abstract classes. Caveats There's a couple of gotchas. First we, syntax must be added to call the imprinted classes's constructors from the imprinting class constructor. Also, what happends if a class imprints two classes which have the same method? In that case the compiler would detect it and force the class to define an override of that method (where you could chose if you wanted to call either imprinted class or both) So what do you think, would it be useful, any caveats? It seems it would be pretty straightforward to implement something like that in the C# language but I might be missing something :) Sidenote - Why is this different from multiple inheritance Ok, so some people have asked about this. Why is this different from multiple inheritance and why not multiple inheritance. In C# methods are either virtual or not. Say that we have ClassB who inherits from ClassA. ClassA has the methods MethodA and MethodB. ClassB overrides MethodA but not MethodB. Now say that MethodB has a call to MethodA. if MethodA is virtual it will call the implementation that ClassB has, if not it will use the base class, ClassA's MethodA and you'll end up wondering why your class doesn't work as it should. By the terminology sofar you might already confused. So what happens if ClassB inherits both from ClassA and another ClassC. I bet both programmers and compilers will be scratching their heads. The benefit of this approach IMO is that the imprinting classes are totally encapsulated and need not be designed with multiple inheritance in mind. You can basically imprint anything.

    Read the article

  • Is the difference between BDD and TDD nothing more than a vocabulary shift?

    - by Desolate Planet
    Hello, I recently made a start on learning BDD (Behaviour Driven Development) after watching a Google tech talk presented by David Astels. He made a very interesting case for using BDD and some of the literature I've read seem to highlight that it's easier to sell BDD to management. Admittedly, I'm a little skeptical about BDD after watching the above video. So, I'm interested to understand if BDD is indeed nothing more than a change in vocabulary or if it offers other benefits.

    Read the article

  • Is this a bad time to be majoring in computer science?

    - by ATMathew
    There has been a lot of media attention paid in recent months and years to the increase in CS majors and the possibility of a second tech bubble. Some news reports have suggested that as more people enter CS, the market could be flooded with CS professionals and jobs could be increasingly difficult to find. Is this a bad time to be majoring in computer science? Edit: I'm a non-trad student who allready has a Bachelor's degree in economics and will be pursuing a CS degree starting this upcoming summer semester at the Univ of Kansas. I've been programming for about two/three years and just need a more formal education to fill the holes in my head. I have an interest in CS, it's just that I am worries about the prospects for the future.

    Read the article

  • How can I backup my PPAs?

    - by Scaine
    Related to this question. But my concern is that over the past year, most of my more interesting (or used) applications are from PPAs, and just backing up my sources list won't add the associated launchpad keys the way that add-apt-repository does. So I'm looking for a way to list all the PPA urls (like ppa:chromium-daily/stable) so that I can easily script a series of add-apt-repository commands to add them into a new installation gracefully. Short of dumping my bash history of course. Which might be feasible, depending on how far back that file goes back?

    Read the article

  • What's wrong with my ext4 partition?

    - by bumbling fool
    What is wrong with this picture? Top is output from "df -h", bottom is gparted. I suspect I'm missing a lot of free space. No problems other than that (yet). Can somebody suggest the best (non-destructive) way to correct this? sudo dumpe2fs -h /dev/sda3: (source http://pastebin.com/nAvrdT4E) Filesystem volume name: <none> Last mounted on: / Filesystem UUID: 9f6eff64-60d7-4eec-81d5-1e8acd818b38 Filesystem magic number: 0xEF53 Filesystem revision #: 1 (dynamic) Filesystem features: has_journal ext_attr resize_inode dir_index filetype needs_recovery extent flex_bg sparse_super large_file huge_file uninit_bg dir_nlink extra_isize Filesystem flags: signed_directory_hash Default mount options: (none) Filesystem state: clean Errors behavior: Continue Filesystem OS type: Linux Inode count: 1602496 Block count: 6406144 Reserved block count: 320306 Free blocks: 4842284 Free inodes: 1361222 First block: 0 Block size: 4096 Fragment size: 4096 Reserved GDT blocks: 1022 Blocks per group: 32768 Fragments per group: 32768 Inodes per group: 8176 Inode blocks per group: 511 RAID stride: 32692 Flex block group size: 16 Filesystem created: Sun Nov 8 18:18:13 2009 Last mount time: Tue Mar 1 01:04:27 2011 Last write time: Mon Feb 28 04:27:34 2011 Mount count: 16 Maximum mount count: 28 Last checked: Thu Feb 24 06:23:39 2011 Check interval: 15552000 (6 months) Next check after: Tue Aug 23 07:23:39 2011 Lifetime writes: 227 GB Reserved blocks uid: 0 (user root) Reserved blocks gid: 0 (group root) First inode: 11 Inode size: 256 Required extra isize: 28 Desired extra isize: 28 Journal inode: 8 First orphan inode: 268015 Default directory hash: half_md4 Directory Hash Seed: cc101517-e617-482b-a883-a72919419c84 Journal backup: inode blocks Journal features: journal_incompat_revoke Journal size: 128M Journal length: 32768 Journal sequence: 0x001d3000 Journal start: 7787 fdisk and parted output per requests: http://pastebin.com/EGVH7Ken

    Read the article

  • Gnome trash on cifs mount random behaviour

    - by BobPenguin
    Hello everyone, I'm seeing some weird behaviour in Ubuntu 10.04. I have a cifs mount that's mounted by fstab as follows: //192.168.1.1/share /media/storage cifs_netdev,username=guest,password="",uid=1000,guid=100,file_mode=0777,dir_mode=0777 0 0 I can mount the share using: sudo mount -a my user can then access it, create and delete files. The deleted files appear in the gnome trash applet. A folder /media/storage/.Trash-1000 is created automatically. When I log out, restart the machine and log in, the cifs share is mounted but the trash applet is empty. If I unmount the share with sudo umount /media/share then remount with sudo mount -a the trash applet displays the contents of the .trash-1000 folder! It gets stranger...sometimes after umount then mount -a the trash is STILL empty, but another round of umount then mount -a fixes it. It seems like the trash applet is "forgetting" to scan the /media/storage mount point and is not always finding the .trash-1000 folder at that mount point. Even when the trash applet is not displaying any trash from /media/storage/.trash-1000 I can still delete things from the /media/storage and they're moved to the .trash-1000 folder. So I conclude there's a bug in the trash applet...anyone know how to fix it?

    Read the article

  • How do I install plc-emu?

    - by user10072
    I have downloaded the tar.gz file for Ubuntu 10.10 64-bit from http://plcemu.sourceforge.net/ but I don't know how to install this. Does anyone know how to install plc-emu from the .tar.zip? Tried but i cant install the software...it gives error melwin@Firefly:~/Desktop/plcemu-14a$ sudo make [sudo] password for melwin: Makefile:25: warning: overriding commands for target `hardware.o' Makefile:23: warning: ignoring old commands for target `hardware.o' cc -O -g -c plcemu.c In file included from plclib.h:1, from plcemu.c:1: plcemu.h:6: fatal error: asm/io.h: No such file or directory compilation terminated. make: *** [plcemu.o] Error 1

    Read the article

  • How to add UTF-8 support to my hard disk in fstab?

    - by punkmexic
    I use Ubuntu (Spanish language). Sometimes I get this error when I use special characters (codification error) so I read that if I edit a file of my hard disk by using gedit /etc/fstab and adding utf8 I can fix it.... I had this line: UUID=bfb5b95e-bf68-464a-8abf-d6027b039fa4 / ext4 errors=remount-ro 0 1 I adeed utf8 like this: UUID=bfb5b95e-bf68-464a-8abf-d6027b039fa4 / ext4 errors=remount-ro,iocharset=utf8 0 1 But I messed my Ubuntu and I can't log in now to my Ubuntu so im using live session... so I'll have to remove that code in order to be able to use my Ubuntu again. Can someone tell me how that line should look like?

    Read the article

  • DockbarX Applet not loading

    - by Nik
    I used to have dockbarX applet installed on my gnome panel. However one day when I login in I got a error message which can be seen in the screenshot below. So I removed it, and then tried adding it again to the gnome panel but I still get the error message. I am running the latest version of dockbarX 0.43 with the helpers enabled and media buttons etc. I did not update it recently and have been using this version for a couple of weeks now and got this problem only now. How can I solve this problem?

    Read the article

  • General input/output error on OpenOffice 3.2

    - by Scott
    I have been working on a research paper in OpenOffice 3.2 Word Processor and I had a slide show OpenOffice 3.2 Presentation. I saved both frequently and they were not very big (no more then 5 pages of text or a few slides). A few days after I last edited and saved them, I tried to open the slide show but I received window saying: General Error. General input/output error When I tried opening the paper, it asked for ASCII Filter Options (font, character, language, and paragraph break). When I set the normal settings, a single blank document opened with nothing on it. I looked at both of the file's properties and the size was 0 or 1.5 KB, and the volume was unknown. I recently installed some updates for Ubuntu 10.10 and everything else in my computer is working normally including other documents and slide shows. Is this a fixable crash?

    Read the article

  • Alot of Pirated Material on Someone's Website - What Can Be Done?

    - by The Russian Shop
    Hi, We've developed our website for over 10 years. Recently a website in China has begun to pirate our images and product descriptions (they are showing "new" March offerings). Nearly all of the items they "offer" are ours. Their whois leads to an outfit in France which by chance also hosts a website for Steroids, and both the Steroid and the pirate site share an 800 phone number (coincidence??). The pirate site lists "their" products as being available in mass quantities, though very often the actual product is one-of-a-kind. The images they've stolen appear in google searches alongside our own!! Clicking on any product at the pirate site leads to nowhere. Calls to the 800 number lead to a recorded answer. No reply to our emails (funny if they would have!) Any suggestions on what to do? Much obliged for any help. https://www.collectiblereview.com (the pirates) http://www.anabolic-store.com (steroids)

    Read the article

  • [SSL] Becoming Root CA

    - by Max13
    Hi everybody, I'm the founder of a little non-profit French organization. Currently, we're providing free web and shell hosting. Talking about that, is there a way to become a Trusted Certificate Authority, in order to give free SSL certificates to my customers, but also to avoid being an intermediate (and pay a lot for that), and/or avoid paying a lot for each certificate... Thank you for your help.

    Read the article

  • The big dude : server cost € , and the what 'i must look for' question .

    - by Angelus
    Hi again and sorry for the bad title . This time I'm thinking in a big project , and I have a big hole of acknowledge about servers and cost of them (economic cost). The big project consist in a new table game for playing online with bets. Think in it like a poker server that must have a good response to thousands of people at the same time. Then i have the big question , what type of server must i look for? , what features must i see in them? . ¿Must I think in cloud computing? thank you in advance.

    Read the article

  • Google search question, front page not showing...

    - by Catelyn
    I know this is probably a dumb question but I hope someone can give me some insight; I was ranked on Google first page of search results for "funny st patricks day shirts" but I was third from the bottom and not familiar enough with SEO, so I signed up for "Attracta" to rank higher. Big mistake. Since using Attracta, I've lost the first page and I'm now on the fourth page in that search. What I noticed is that Google is now just showing a sub-page or side page, (a link from my front page, to a page which has only a few designs in it) this is not where I would want customers to land first... but my front page is not showing in that search anymore. Obviously, the title of this side page is not geared toward that search result, so I know that's why I have the pr drop. Why is my front page not ranking over that page, though? Why is it apparently gone from that search, or so far back no one will ever find it? I need to know how to fix this quick if anyone has any advice at all for me. It's the busiest season for my website and the people who were stealing design ideas from me are all ranked higher than my site now. (I can prove this, lol) So, I'm very frustrated by that. I would be very grateful to have any advice at all as to what I can do to fix this. THANKS in advance for any advice you can offer. Catelyn

    Read the article

  • Managing game objects/components

    - by Xeon06
    Good day everyone, By far the biggest problem that has always dawned on my when programming games is how to structure my code. It just becomes an incredible mess after a while. The reason for that is because I have no idea how different classes should interact with each other. Let's have an example. Say I have a class Player, a class PlayerInput and a class Map. The player class contains information as to the location of the player, whereas the player input class handles changing that location, but by first making sure it's within a walkable area from the map class. How to structure this? My usual approach is to pass those components as parameters in the constructors of the parameters that need them, like so: var map = new Map(); var player = new Player(); var input = new PlayerInput(player, map); The problem with that is that it quickly gets messy, when you add new components you have to go through your constructors and update them, and it doesn't work well if you have mirroring references: var physics = new Physics(input); //Oops, doesn't work var input = new Input(physics); So, how do you guys usually manage this? Thanks.

    Read the article

  • Beginners' Guide to Development

    - by Bombillazo
    Hello. So I have some experience programming in Java, and at the moment I am learning how to use Python. I have read on the process of game design and such. I also have media covered, got experience with graphics and audio. My question is geared more towards the actual tools to use for making games, developing. I am willing to commit to a long term development cycle, as I will be doing this as a hobby. I've heard of Flash, Gamemaker, etc. I don't intend to create my own Game Engine, so I was looking for a platform that is extensible and easy to program with an OOP mind frame. As a plus it would be great of said game could be played directly from a website. TIA!

    Read the article

  • Best way to do large XNA animations?

    - by Harold
    What's the best way to have large animations in XNA 4.0? I have created a spritesheet with the sprite being 250x400 (more of an image than a sprite but hey ho) and there are approximately 45 frames in the animation. This causes problems for XNA as it says that the maximum filesize for Reach is 2048. I'd rather not change to hidef as I heard that means that your game is less compatible with some computers and systems so does anyone have any idea what the best thing I could do is? The only thing I could come up with is to have a list of textures to flick through but that's not ideal.

    Read the article

< Previous Page | 5 6 7 8 9 10  | Next Page >