Categories
iPhone app

Developer EQ series : 1

Reading Time: < 1 minute

Dont’s
Beat up people in code review or interview;

Change other developers’ code without proper communication, or reasoning; worse, making the working code no longer work (sometimes to satisfying the “tests” 🙂

Do’s
Learn, learn something everyday;

Acknowledge our own limitations: acknowledge our mistakes if applicable, we all do make mistakes;

In the same token, when we learn something from someone else, show our appreciation;

PS, also came across this piece “assertiveness from developers” by Jeff Atwood (@codinghorror), which I think is excellent. Essentially the point there is be a good developer is not to be a “nice person to everyone”. A good developer uses his/her best judgement, and speaks from his/her own mind, which includes saying something make other stakeholder uncomfortable (as long as it’s fair and honest statement).

And, slightly off topic, this one “Your Company Is Not A Family” from HBR (Harvard Business Review).

Categories
Fun video

Let it go

Reading Time: < 1 minute

and Chinese version.

Categories
iPhone app

Swift might the the language of the future

Reading Time: < 1 minute

Apple : the Swift language (unveiled in WWDC on June 2, 2014)

Tutorials
Developing iOS Apps Using Swift Tutorial Part 1 (Jameson Quave)

learnswift.tips

References and reviews
Matt Galloway : Swift Language Highlights: An Objective-C Developer’s Perspective (raywenderlich.com)

The Verge : The Swift effect: Apple’s new programming language means way more iPhone developers and apps

Ray Wenderlich: Swift Cheat Sheet and Quick Reference (raywenderlich.com)

arstechnica.com : A fast look at Swift, Apple’s new programming language

Btw, Jeff Lamarche (twitter: @jeff_lamarche), the author of Beginning iPhone/iOS Development book, already got book offers for the Swift language. At the same time, don’t throw away Objective-C yet (HuffintonPost).

photo-3

Categories
iPhone app

Some tips for submit app to iTunes App store

Reading Time: 2 minutes

Avoid the Payload validation error
To shorten the review waiting time. I noticed this recently in my own apps update. The one without warning has much shorter review waiting time. The rationale is App thinks the app may use private API in this scenario (see this explanation on stackoverflow). From personal experience the one with warnings could be in the “wait for review” queue at least one week longer than the one without warning. So clean up the code if we can. Btw, I was able to fix the first one below (it turns out to be a third party function I no longer use). For the second one below, I read it could be related to Facebook SDK (which my app uses), but have NOT been able to solve it for now.

collegeFund_submit_warnings

ToMarket_submit_upload_warn

Validation
Validate before submit to App store, in Xcode organizer.

Keywords
Try put in relevant key words for the app during update (the only time we can change it); we can find some useful keyword by search App store. Also keep in mind search does not work all the time on iPhone.

Code Signing
This one is very subtle. I had two certificates, one was used both for dev and distribution; another one was for distribution (Ad hoc or App store). I found initially I could not sign the app by using the distribution certificate (provisioning profile) alone. After back and forth I was able to sign. And as I look at the certificate in Xcode now, it’s refers to the Ad hoc certificate, but in the submission process it still prompts the first one.

    Categories
    iPhone app

    Ads or no ads

    Reading Time: 2 minutes

    Should I put iAd to my iOS apps on iTunes App store? Should I put the google adsense back to my blog? The reason I am asking this question is: while personally I really don’t like the ads on Facebook, LinkedIn, or the iAds on some apps like Echofon, I understand this is a meaningful way for app developers to make some money. This applies to me as well. While I did not spend whole a lot time working on my apps (in aggregate), I cannot go on this app dev road without any meaningful downloads/income revenue forever. I can do it for a while. But not for too long. I believe Ray Wenderlich talked about the importance of Ad revenue at recent raywenderlich.com podcast. One of the episode of Paul Kemp’s the App Guy Podcast (onemob.com) , talked about something similar.

    I guess, the trick is to balance the ads and app. We don’t want ads to totally destroy the good experience of an app, but at the same time, if the app revenue could help the developer keep going, go for it. We live in a commercial world, no money, no bread. No bread, how can app developers survive?

    photo

    Btw, I found the Apple developer documentation for iAd is insufficient or not up-to-date. For example, it uses requiredContentSizeIdentifiers in the tutorial, which is already deprecated in iOS 6. I found it won’t compile with iOS 7 SDK. I have seen in the past Apple does not always updates its developer documentation. Maybe they have not given high priority to this. I am sure if they pay attention, they can fix it.

      Categories
      Software development

      Singleton pattern backfired on me

      Reading Time: 2 minutes

      This is a continuation of my earlier post of Tree, recursive function and my dumb mistake. As I said in my last post, my solution was to create hash maps (singleton) to store those for the session. The main motivation was to help out the performance. But I found out it backfired on me, a few days ago and today. In both cases, it has to do with the hash map I created, it was something like (object , a list of objects). In both cases the list of objects was actually dynamic, and I made an assumption it was static. In other words, I thought I only need to put the mapping to the map once, then I can use it happily ever after. I think there might be ways to get around it, i.e., I should update the map when that list does change. I will investigate and work on it more. (Update 05-30-14) So I found a solution to one scenario, I was able to update the map as needed. And I use put method (java hashmap) to do that update.

        Categories
        iPhone app Software development

        What types of developer are you?

        Reading Time: 3 minutes

        Or am I? 🙂 I think I’m a pragmatic programmer. Note this is also a book title I read, by pragmatic (note not agile), I think it’s about balance between software quality, effort and delivery date. It’s also about releasing software with known risks (including bugs) 🙁

        Pragmatic_Programmer

        I thought about this as I started practicing some new (new to me) programming techniques, e.g., pair programming, test driven development (TDD), and also seen developers of different personalities/experience adjusting to this, at the same time trying to deliver the project on schedule. I felt and considered myself to be lucky in this aspect, as I thought my career at UGS/Siemens PLM Software laid the foundation for me as developer, in other words, I was very lucky to work with some excellent developers (definitely top 20% according to Jeff Atwood, co-founder of stack overflow), and received their guidance and mentoring in my programming formative years. Note I was not doing Agile, TDD, pair programming at that time, at least not formally. But at the latter part of my stay there, I did quite a bit automated unit/regression tests there. Also, although there is no pair programming, whenever I feel stuck, I could go to a senior member of the team, and talk. Not to mention the long debug session. I wrote about them in my blog long time ago (in Chinese, such as this one and this one).

        Categories
        iPhone app

        Three good iOS Mac focused podcast

        Reading Time: 2 minutes

        I have listened to Paul Kemp’s the App Guy Podcast (TAGP) recently, got to know this from @raywenderlich via twitter. Paul’s podcast is not purely technical, it’s more about entrepreneurship, and start own business. It’s an interview format. Paul usually asks indie developers (iOS, web, etc.) questions on how they get started, any pain points or difficulties to strike out on own, vs. getting steady paycheck from corp. Paul himself is an indie developer/podcast too. I think Paul is a good interviewer because he asks good questions, which reminds me of other good/great interviewer such as Charlie Rose (PBS/CBS), and Wealthtrack’s Consuelo Mack (formerly PBS). Again this is not only about blocks, MVC, Xcode, but more about going indie (independent developer).

        Another good podcast, which started recently, is raywenderlich’s. There we have Ray plus 4 developers (Tammy, Jake, Felipe, and Mic). It’s more technical, but it also covers going indie. For that matter, the 4 podcasters have been going indie for some time, and Ray himself was an independent developer before the tutorial site/book took off. So they have a lot to share. And we (as techies) got to listen all the nitty gritty of NSNotifications, design patterns as well, which is cool.

        Categories
        Software development

        Dumb code mistake continues

        Reading Time: < 1 minute

        So I was able to fix that performance problem I mentioned in my previous post. But I inadvertently introduced a new problem in my previous fix. And here is the gist of how I did:


        while (some condition) {
        if(some other condition) {
        ...
        return;
        }
        }

        Guess what, I was able to put it into infinite loop…I can explain more if needed 🙂

        Categories
        Software development

        Tree, recursive function and my dumb mistake

        Reading Time: < 1 minute

        Tree data structure is fairly common in software development, and luckily I have quite a bit experience working on those in my career. I started working on this as I was working for UGS/Siemens PLM Software, and I was involved in the development of XML based data adapter for CAD data exchange, a key piece of information we want to translate is the assembly information, or product structure, or in computer/software terms, the tree hierarchy. I did learned a few things on recursive function, etc. Interestingly enough, later on I got a interview phone call from Google, and the guy asked me about recursion, for a simple problem like this: basically they are 100 matches, every time one can take one or 2, how many combinations are there? I said let’s do it in recursive fashion, after quite a bit reminder/hint, finally I said n(100) = n(99) + n(98)

        But they were not very impressed with me, as I did not come up with the solutions fast enough, which is fine. I am who I am, I can work on those kind of interesting problems, in my own pace. Or explained in my Chinese name, it’s getting faster gradually 🙂

        My dumb mistake