Swift 2.0 for programmers Part#4

Structures Points to be noted Int, Bool, Double, String, Array, Dictionary are all structures, not class struct is identical to class. Change a class keyword to struct keyword and everything should work fine Differnece between struct and class Structures are value types (pass by value) unlike class Swift generates member wise intializer for struct. Member … Continue reading Swift 2.0 for programmers Part#4


Swift 2.0 for programmers Part#3

Class Inheritance Computer property Class level/Type level/Static members Lazy property Points to be noted lazy can not be constant variable, i.e can not started with let lazy property won't get initialized until the variable gets called Observers Access Modifies Points to be noted There are 3 access modifiers: private, internal, public private: Accessible from the … Continue reading Swift 2.0 for programmers Part#3

Swift 2.0 for programmers Part#2

Arrays Points to be noted Arrays are typed Arrays are mutable when created with var Arrays are immutable when crated with let Dictionary Optionals Tuple Enum Closures Points to be noted Closures group code into a self-contained, reusable unit Functions are a type of closure Closure doesn't have a name unlike functions In other languages … Continue reading Swift 2.0 for programmers Part#2

Swift 2.0 for programmers Part#1

Key points about Swift programming language: Swift is not a superset of C or C++. Whereas, Objective-C was a superset of C. Swift statements do not require semicolon. The compiler won't complain if you use one, but it is recommended not to. There is no main method/function in Swift. Code executes from top and works … Continue reading Swift 2.0 for programmers Part#1

UIU: Learn C++ STL by Examples : Vector

ভেক্টর হল Dynamic array; যেমন, আমরা যখন array declare করি তখন আমাদের সাইজ বলে দিতে হয়। কিন্তু যদি এমন হয়, আমি আগের থেকেই জানি না সাইজ কত হতে পারে; তখন আমরা ভেক্টর ব্যবহার করতে পারি। ভেক্টর ব্যবহার করলে আগের থেকেই সাইজ বলে দেয়ার দরকার হয় না। প্রথমে আমাদের ১. ভেক্টর declare করতে হয়। ২. তারপর … Continue reading UIU: Learn C++ STL by Examples : Vector

Android: Java and JavaScript Interfacing in Android Webview

points: # do not run on android emulator 2.3.x. there is a severe bug and so far not resolved. run on android sdk api >= 8 # put the index.html file in assets folder # click on javaButton will change the background color of the webView by calling a Js function # click on the … Continue reading Android: Java and JavaScript Interfacing in Android Webview