<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-6068884217450514184</id><updated>2011-12-22T01:50:37.168-08:00</updated><category term='ShareApp Fix'/><category term='recovery partition'/><category term='Richard Feyman'/><category term='Visual Studio'/><category term='Diskpart'/><category term='reinterpret cast'/><category term='i9003'/><category term='dynamic cast'/><category term='Outlook'/><category term='DispatchMessage'/><category term='TouchWiz3'/><category term='SIP'/><category term='Windows'/><category term='puzzle'/><category term='Gladinet'/><category term='CR313H'/><category term='VGP-VCC6'/><category term='SD Card Reader'/><category term='icon background tiles'/><category term='Chrome OS from USB'/><category term='windows 7'/><category term='Embedded'/><category term='pointers'/><category term='linkage'/><category term='Games'/><category term='timer'/><category term='Graphics'/><category term='Gingerbread'/><category term='MsConfig'/><category term='Switch Utility'/><category term='Dock Icons'/><category term='makefile'/><category term='i9100'/><category term='busybox'/><category term='eclipse'/><category term='activation'/><category term='strings'/><category term='c++'/><category term='Services'/><category term='Logical Thinking'/><category term='Android Apps'/><category term='Gingerbreak'/><category term='ADB'/><category term='Galaxy SL'/><category term='Brightness Keys'/><category term='typeid'/><category term='arrays'/><category term='TouchWiz4'/><category term='Android 2.3.4'/><category term='static cast'/><category term='stack direction'/><category term='Favorite Andoird Apps'/><category term='cloud'/><category term='algorithm'/><category term='syntax error eclipse'/><category term='compile'/><category term='Smart Phone'/><category term='Nymgo'/><category term='c'/><category term='interview'/><category term='Slow'/><category term='MSVC'/><category term='Andorid-x86'/><category term='XXKPH'/><category term='Ricoh'/><category term='blogger tools'/><category term='little endian'/><category term='Google Music'/><category term='virtual pc 2007'/><category term='ubuntu'/><category term='windows xp mode'/><category term='big endian'/><category term='kannada'/><category term='compiler'/><category term='static linking'/><category term='Ubuntu 10.10'/><category term='Vista'/><category term='mangling'/><category term='asynchronous'/><category term='activation without product key'/><category term='debugging'/><category term='mixed language'/><category term='Root'/><category term='Windows Live Writer'/><category term='Best Andoird Games'/><category term='Wirless LAN Switch'/><category term='typecast'/><category term='Chromium'/><category term='make ubuntu look like windows 7'/><category term='extern'/><category term='Android Debug Bridge'/><category term='Picasa'/><category term='Samsung Apps'/><category term='Dual boot'/><category term='virtual pc'/><category term='SDL'/><category term='CSipSimple'/><category term='Google Andorid'/><category term='linux kernel'/><category term='Regedit'/><category term='Storage'/><category term='virtual hard disk'/><category term='Android'/><category term='Polaris Office'/><category term='Mouse Scroll'/><category term='Web Cam'/><category term='Illegal Questions'/><category term='icon tiles'/><category term='gdb server'/><category term='const cast'/><category term='Chrome OS'/><category term='icon backdrops'/><category term='dll programming'/><category term='TimerProc'/><category term='customize'/><category term='Android Games'/><category term='Sony Vaio'/><category term='Galaxy S-II'/><category term='TouchWiz'/><category term='UNetbooin'/><category term='stack'/><category term='Function Keys'/><category term='windows 7 theme for ubuntu'/><category term='dynamic linking'/><category term='device driver'/><category term='Google Interview Questions'/><category term='data structures'/><category term='linked list'/><category term='samba server'/><category term='qemu'/><category term='Putty'/><category term='Skydrive'/><category term='Samsung'/><category term='product key'/><category term='inter-working'/><category term='Microsoft Interview'/><category term='VOIP'/><category term='Issues'/><category term='Login'/><title type='text'>Techology for All</title><subtitle type='html'>This is a blog dedicated to all those problems I faced while making some things work, I might have struggled a lot to get the information from the net, this is to make my life easy whenever next time I want to do the same, or for someone who is in need of help, this may make their life easy too. Thanks for visiting my blog, feel free to mail me in case you have any questions.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>81</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-5682752220474137607</id><published>2011-12-10T23:41:00.001-08:00</published><updated>2011-12-10T23:48:05.105-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='SIP'/><category scheme='http://www.blogger.com/atom/ns#' term='Nymgo'/><category scheme='http://www.blogger.com/atom/ns#' term='VOIP'/><category scheme='http://www.blogger.com/atom/ns#' term='Galaxy S-II'/><category scheme='http://www.blogger.com/atom/ns#' term='Galaxy SL'/><category scheme='http://www.blogger.com/atom/ns#' term='CSipSimple'/><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><title type='text'>Configuring CSipSimple SIP client on Galaxy SL for Nymgo</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div&gt;Here is the configuration to be done.&amp;nbsp;These is carefully written to cover most of the points and a hastle free experience when you do the setup.&amp;nbsp;You can refer to nymgo.com site, they have given some basic info, it would serve as reference.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;First when adding account, you need to select the &lt;b&gt;Basic Wizard.&lt;/b&gt;&lt;/div&gt;&lt;div&gt;Menu Key -&amp;gt; Accounts &amp;nbsp;-&amp;gt; Add Account &amp;nbsp;-&amp;gt; Generic Wizards -&amp;gt; Basic&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/-b2gGDIeLPVg/TuRe1WeYy0I/AAAAAAAAHJg/o4jbtH7V6Z0/s1600/snap20111211_125924.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://1.bp.blogspot.com/-b2gGDIeLPVg/TuRe1WeYy0I/AAAAAAAAHJg/o4jbtH7V6Z0/s320/snap20111211_125924.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;&lt;b&gt;Account Name:&lt;/b&gt;&amp;nbsp;Nymgo&lt;/li&gt;&lt;li&gt;&lt;b&gt;User:&lt;/b&gt; Nymgo User Name&lt;/li&gt;&lt;li&gt;&lt;b&gt;Server:&lt;/b&gt;&amp;nbsp;ata.nymgo.com (no need to give port number even though we knows its 80, it would be taken care by wizard, and if you give, it seems to be not working for me)&lt;/li&gt;&lt;li&gt;&lt;b&gt;Password:&amp;nbsp;&lt;/b&gt;Nymgo Password.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div&gt;You are almost done !!&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Next thing is that, we should be using UDP for communication, so&amp;nbsp;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://3.bp.blogspot.com/-3awJRYygVdM/TuRfNKov8GI/AAAAAAAAHJo/175zn87S_VQ/s1600/snap20111211_130018.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://3.bp.blogspot.com/-3awJRYygVdM/TuRfNKov8GI/AAAAAAAAHJo/175zn87S_VQ/s320/snap20111211_130018.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Menu Key (Left Soft Key in Galaxy S) -&amp;gt; Settings -&amp;gt; Network&lt;/div&gt;&lt;div&gt;Do the following settings -&amp;gt;&lt;i&gt; UDP port number set as 5060&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Stun should be on -&amp;gt; set it to stun.nymgo.com:80&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-iDtfcV7lfOM/TuRfWAURjPI/AAAAAAAAHJw/v49PZWBOUHA/s1600/snap20111211_130035.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://2.bp.blogspot.com/-iDtfcV7lfOM/TuRfWAURjPI/AAAAAAAAHJw/v49PZWBOUHA/s320/snap20111211_130035.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Set Networks for All outgoing calls.&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/-c-l27eSlXvw/TuRfcJz4vAI/AAAAAAAAHJ4/7QZlj5p-DWs/s1600/snap20111211_130155.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://4.bp.blogspot.com/-c-l27eSlXvw/TuRfcJz4vAI/AAAAAAAAHJ4/7QZlj5p-DWs/s320/snap20111211_130155.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Settings -&amp;gt; Media&lt;/div&gt;&lt;div&gt;* You need to disable all codecs except below ones&lt;/div&gt;&lt;div&gt;&amp;nbsp; &amp;nbsp;G729 8Khz (Wideband)&lt;/div&gt;&lt;div&gt;&amp;nbsp; &amp;nbsp;G729 HKhz (Narrowband)&lt;/div&gt;&lt;div&gt;* Use Samsung Galaxy Hack [ checked ]&lt;/div&gt;&lt;div&gt;* Micro / Speaker amplification can be used if audio is very low, I have used mirco to 5 and audio as it is.&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/-NcdQt72zLtc/TuRfi9-VetI/AAAAAAAAHKA/zK7nczRzXis/s1600/snap20111211_130413.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://4.bp.blogspot.com/-NcdQt72zLtc/TuRfi9-VetI/AAAAAAAAHKA/zK7nczRzXis/s320/snap20111211_130413.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Settings -&amp;gt; Call options&lt;/div&gt;&lt;div&gt;Caller id -&amp;gt; Set to your own number, if you have used caller id feature in Nymgo.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Settings -&amp;gt; Filters&amp;nbsp;&lt;/div&gt;&lt;div&gt;These can be used when you have enabled the Android integration, and can be used to make sure all numbers starting with +91 (India) can be made to go through phone dialer and International calls through Nymgo,&amp;nbsp;I have enabled it, but its optional, let me know if you have any questions here.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Once the configuration is done, dial 111 from your SIP dialer and wait for Nymgo test service, and you would be able to test if you configuration is working fine, if you could hear your own voice back after recording, then you are ready to use nymgo, feel free to drop your comments and queries, I would be glad to help you.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-5682752220474137607?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/5682752220474137607/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/12/configuring-csipsimple-sip-client-on.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5682752220474137607'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5682752220474137607'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/12/configuring-csipsimple-sip-client-on.html' title='Configuring CSipSimple SIP client on Galaxy SL for Nymgo'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/-b2gGDIeLPVg/TuRe1WeYy0I/AAAAAAAAHJg/o4jbtH7V6Z0/s72-c/snap20111211_125924.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-5504143888411882514</id><published>2011-11-12T21:30:00.001-08:00</published><updated>2011-11-12T21:44:33.172-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Samsung'/><category scheme='http://www.blogger.com/atom/ns#' term='ADB'/><category scheme='http://www.blogger.com/atom/ns#' term='Android Apps'/><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><category scheme='http://www.blogger.com/atom/ns#' term='Samsung Apps'/><category scheme='http://www.blogger.com/atom/ns#' term='Android 2.3.4'/><category scheme='http://www.blogger.com/atom/ns#' term='Android Debug Bridge'/><title type='text'>Some of the useful info when working with ADB on phone</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;&lt;div style="text-align: -webkit-auto;"&gt;&lt;div&gt;For remounting the system partition as RW on Galaxy SL, (need to be super user)&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;# mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;For mounting back to RO&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;# mount -o ro,remount -t yaffs2 /dev/block/mtdblock3 /system&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Basic ADB commands&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;# adb push &amp;lt;local_path&amp;gt; &amp;lt;remote_path&amp;gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;# adb pull &amp;lt;remote_path&amp;gt; &amp;lt;local_path&amp;gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;# adb install &amp;lt;path_to_apk&amp;gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;If you have not installed the cp command may not work, the work around would be&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;# cat [source_file] &amp;gt; [destination_file]&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;The command binaries would be located at this location, /system/bin/ And if you had installed busybox, in /system/xbin/ then first the above path is looked for command, and later the below path.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;The /system partition has limited memory, so if you try installing too many applications here, then you may run out of space, and its a better idea to delete many of the unwanted bloat applications from there. I have deleted the following apps and they do not be of much use for me. May be if its not useful for you, you can delete them as well. And you can also delete any other apps which are of no use for you.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;ol style="text-align: left;"&gt;&lt;li&gt;Samsung Apps [They are meant for Bada, and of no use in Android! wonder why its added here!]&lt;/li&gt;&lt;li&gt;BuddiesNow.apk/odex&lt;/li&gt;&lt;li&gt;thinkdroid.apk/odex [ThinkFree Office - I have installed Polaris Office instead of this, which is much better]&lt;/li&gt;&lt;li&gt;Day.apk/odex&lt;/li&gt;&lt;li&gt;DualClock.apk/odex&lt;/li&gt;&lt;li&gt;SamsungWidget_Calenderclock.apk/odex&lt;/li&gt;&lt;li&gt;SamsungWidget_Feedandupdate.apk/odex&lt;/li&gt;&lt;li&gt;SamsungWidget_stockclock.apk/odex&lt;/li&gt;&lt;li&gt;SamsungWidget_Weatherclock.apk/odex&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;&lt;div style="font-family: inherit;"&gt;All the best, and keep a backup of the file before altering or deleting any file inside /system partition, so that you can restore if something goes wrong, and I am not responsible for any thing if at all it goes wrong :)&lt;br /&gt;Some useful tips and tricks about galaxy S/SL can be &lt;a href="http://tips.developersvoice.com/index.php?s=galaxy+s"&gt;found here&lt;/a&gt;, its quite long, but when free go through.&lt;/div&gt;&lt;/div&gt;&lt;div style="font-family: Tahoma;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-5504143888411882514?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/5504143888411882514/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/11/some-of-useful-info-when-working-with.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5504143888411882514'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5504143888411882514'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/11/some-of-useful-info-when-working-with.html' title='Some of the useful info when working with ADB on phone'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-6488763813187190378</id><published>2011-10-03T09:37:00.000-07:00</published><updated>2011-10-03T09:37:56.536-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Polaris Office'/><category scheme='http://www.blogger.com/atom/ns#' term='Galaxy SL'/><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><category scheme='http://www.blogger.com/atom/ns#' term='Android 2.3.4'/><category scheme='http://www.blogger.com/atom/ns#' term='i9003'/><title type='text'>Install Polaris Office of Galaxy S2 on Galaxy SL i9003</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;Polaris office is one of the office suite for mobile, similar to the many available for mobile phones. Galaxy SL comes with think free office, which is also good, but formatting, editing are much better in Polaris office.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;You need to have root for installing this application, as it needs to be installed in system folders. I have referred to this&lt;a href="http://forum.xda-developers.com/showthread.php?t=1135171"&gt; post of xda for&lt;/a&gt; installation and also &lt;a href="http://forum.xda-developers.com/attachment.php?attachmentid=632918&amp;amp;d=1308730394"&gt;downloaded from the link provided there&lt;/a&gt;.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-wwMlKI779GM/TonkiewDvDI/AAAAAAAAHHc/-4rTAjNcsa8/s1600/snap20111003_162101.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://2.bp.blogspot.com/-wwMlKI779GM/TonkiewDvDI/AAAAAAAAHHc/-4rTAjNcsa8/s320/snap20111003_162101.png" width="211" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Here is the procedure to follow to install the same&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;1. Extract the files from compressed file&lt;/div&gt;&lt;div style="text-align: justify;"&gt;2. Copy apk from app to /system/app&lt;/div&gt;&lt;div style="text-align: justify;"&gt;3. Copy files from lib folder to /system/lib&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;You may have to free some space in /system folder as that partition is of limited size, and you may need to delete unwanted applications and may be you can delete the think free application.&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-6488763813187190378?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/6488763813187190378/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/10/install-polaris-office-of-galaxy-s2-on.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/6488763813187190378'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/6488763813187190378'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/10/install-polaris-office-of-galaxy-s2-on.html' title='Install Polaris Office of Galaxy S2 on Galaxy SL i9003'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/-wwMlKI779GM/TonkiewDvDI/AAAAAAAAHHc/-4rTAjNcsa8/s72-c/snap20111003_162101.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-370716354642405977</id><published>2011-09-27T04:12:00.000-07:00</published><updated>2011-09-27T04:12:44.422-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='XXKPH'/><category scheme='http://www.blogger.com/atom/ns#' term='Galaxy S-II'/><category scheme='http://www.blogger.com/atom/ns#' term='i9100'/><category scheme='http://www.blogger.com/atom/ns#' term='Gingerbread'/><category scheme='http://www.blogger.com/atom/ns#' term='Galaxy SL'/><category scheme='http://www.blogger.com/atom/ns#' term='TouchWiz4'/><category scheme='http://www.blogger.com/atom/ns#' term='TouchWiz'/><category scheme='http://www.blogger.com/atom/ns#' term='i9003'/><category scheme='http://www.blogger.com/atom/ns#' term='Dock Icons'/><title type='text'>Update i9003 with Galaxy S-II Dock Icons</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;Bored of the same dock bar at the home screen, and you think the Galaxy S-II one looks much better. Its not difficult to update it to that. All that you need it root permissions.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;I could not get this full information in one place on net, so if you are reading my blog you are lucky to have all the information in one place. You do not need to install a custom TouchWiz, you can modify what you have right now. I am running TouchWiz 4.0 for your information. (Galaxy SL - Gingerbread 2.3.4 XXKPH)&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;First have copy Contact.apk, Email.apk, Mms.apk and TouchWiz30Launcher.apk &amp;amp; DialerTabActivity from system/app to PC, then Open it with any tools such as Winrar or 7Zip, do not extract.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; border-collapse: separate; orphans: 2; text-indent: 0px; widows: 2;"&gt;&lt;div style="-webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; text-align: justify; text-transform: none; white-space: normal; word-spacing: 0px;"&gt;check the icons in the path - res/drawable-hdbi.&lt;/div&gt;&lt;span class="Apple-style-span"&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;-Contakt.apk: ic_launcher_contacts.png&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;div style="text-align: justify;"&gt;-DialerTabActivity - ic_launcher_phone.png&lt;/div&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;div style="text-align: justify;"&gt;-Mms.apk: ic_launcher_smsmms.png&lt;/div&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;div style="text-align: justify;"&gt;-Email.apk: icon.png&lt;/div&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; border-collapse: separate; orphans: 2; text-indent: 0px; widows: 2;"&gt;&lt;div style="-webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; text-align: justify; text-transform: none; white-space: normal; word-spacing: 0px;"&gt;-TouchWiz30Launcher.apk: mainmenu_icon_application.png and mainmenu_icon_home.png.&lt;/div&gt;&lt;span class="Apple-style-span"&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;div style="text-align: justify;"&gt;Replace all these icons with new Icons and drag and drop into the 7Zip explorer.&lt;/div&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; border-collapse: separate; orphans: 2; text-indent: 0px; widows: 2;"&gt;&lt;div style="-webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; text-align: justify; text-transform: none; white-space: normal; word-spacing: 0px;"&gt;Copy the .apk fils back to system/app and restart the launcher or the phone.&lt;/div&gt;&lt;span class="Apple-style-span"&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;div style="text-align: justify;"&gt;It should look something like this, after you have updated everything that is mentioned here.&lt;/div&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/-ZFxiobV_1zo/ToGvRJUAN4I/AAAAAAAAHHY/dBMgBcH4Sdc/s1600/%255BQ%255D+Different+Icons+at+Bottom-Dock+-+xda-developers.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="136" src="http://4.bp.blogspot.com/-ZFxiobV_1zo/ToGvRJUAN4I/AAAAAAAAHHY/dBMgBcH4Sdc/s320/%255BQ%255D+Different+Icons+at+Bottom-Dock+-+xda-developers.png" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;That goes with many stock apps.&lt;span&gt;&amp;nbsp;&lt;/span&gt;I hope its useful.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;The Samsung Galaxy S-II icons can be downloaded from here.&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://www.multiupload.com/M37PRRW18J"&gt;http://www.multiupload.com/M37PRRW18J&lt;/a&gt;. More info can be found &lt;a href="http://forum.xda-developers.com/showthread.php?t=1050817"&gt;here&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-370716354642405977?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/370716354642405977/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/update-i9003-with-galaxy-s-ii-dock.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/370716354642405977'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/370716354642405977'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/update-i9003-with-galaxy-s-ii-dock.html' title='Update i9003 with Galaxy S-II Dock Icons'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/-ZFxiobV_1zo/ToGvRJUAN4I/AAAAAAAAHHY/dBMgBcH4Sdc/s72-c/%255BQ%255D+Different+Icons+at+Bottom-Dock+-+xda-developers.png' height='72' width='72'/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-3751048175976917376</id><published>2011-09-25T23:10:00.000-07:00</published><updated>2011-09-26T08:08:37.967-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='icon backdrops'/><category scheme='http://www.blogger.com/atom/ns#' term='Galaxy SL'/><category scheme='http://www.blogger.com/atom/ns#' term='TouchWiz4'/><category scheme='http://www.blogger.com/atom/ns#' term='icon tiles'/><category scheme='http://www.blogger.com/atom/ns#' term='TouchWiz3'/><category scheme='http://www.blogger.com/atom/ns#' term='icon background tiles'/><category scheme='http://www.blogger.com/atom/ns#' term='i9003'/><category scheme='http://www.blogger.com/atom/ns#' term='customize'/><title type='text'>Customize Icon Tiles for Galaxy SL i9003</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;As I had mentioned in the previous post about the TouchWiz 4.0, the icon backdrops/tiles are not set as it should be. I mean to say, even though in the apk, all of the tiles have been named as to which icon it should be applied, they are not been applied to them. My belief is that it must be because of the mismatch of the binary and the TouchWiz 4.0 apk, but I am not sure. I need some expert to comment here.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;I have&amp;nbsp;&lt;a href="http://forum.xda-developers.com/showthread.php?t=796704"&gt;referred&amp;nbsp;to this post&lt;/a&gt;, and worked my way, it was mean for touchwiz 3.0 for getting rid of the icon tiles by replacing them with transparent ones. I have followed the same procedure and replaced the unwanted tiles with the one I want to have.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://3.bp.blogspot.com/-2gwvGuqXV7c/ToCU5LnJH_I/AAAAAAAAHHQ/8dy0mTcAbO8/s1600/snap20110926_203214.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://3.bp.blogspot.com/-2gwvGuqXV7c/ToCU5LnJH_I/AAAAAAAAHHQ/8dy0mTcAbO8/s320/snap20110926_203214.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;All you need to have is a &lt;b&gt;rooted phone, &lt;/b&gt;because for replacing touch wiz files you need to have root permissions. You also need to have ADB and Tool like Winrar or 7Zip. I use 7zip.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;First take out the TouchWiz30Laucnher.apk file located in the '/system/app' folder and put on your desktop or somewhere. Use the below command.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="font-family: 'Courier New', Courier, monospace;"&gt;adb pull /system/app/TouchWiz30Launcher.apk &amp;lt;local_path&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: 'Courier New', Courier, monospace; font-size: x-small;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Now you can open this apk file in 7Zip, do not extract, but replace the tiles you want by directly dragging and dropping in to the 7Zip window. The tiles would be located at&amp;nbsp;&lt;/span&gt;'/res/drawable-hdpi-v4/' or similar folder, use your common sense, they would start with something like 'mainmenu or homescreen' and end with '_bg.png' &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Once you are done replace this apk with the original apk present in the '/system/app/' folder. remember to keep a copy in case if you have done something wrong. &lt;/span&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="color: #111111; font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;In the windows command prompt, use adb push to push the apk into SD Card.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="color: #111111; font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/-grVnK2_EWNQ/ToCU6sgL1QI/AAAAAAAAHHU/6jmcZUmlNQY/s1600/snap20110926_203249.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://1.bp.blogspot.com/-grVnK2_EWNQ/ToCU6sgL1QI/AAAAAAAAHHU/6jmcZUmlNQY/s320/snap20110926_203249.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="font-family: 'Courier New', Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;gt; adb push &amp;lt;local_path&amp;gt;\TouchWiz30Launcher.apk /sdcard/&lt;br /&gt;&amp;gt; adb shell&lt;br /&gt;$ su&lt;br /&gt;# mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system&lt;br /&gt;# mv /system/app/TouchWiz30Launcher.apk /system/app/TouchWiz30Launcher.apk.bak&lt;br /&gt;# cp /sdcard/TouchWiz30Launcher.apk /system/app/TouchWiz30Launcher.apk&lt;br /&gt;# chmod 744 TouchWiz30Launcher.apk&lt;br /&gt;# mount -o ro,remount -t yaffs2 /dev/block/mtdblock3 /system&lt;br /&gt;# exit&lt;br /&gt;$ exit&lt;br /&gt;&amp;gt; exit&lt;/span&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="color: #111111; font-family: 'Courier New', Courier, monospace; font-size: x-small; line-height: 19px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span"&gt;&lt;span class="Apple-style-span" style="color: #111111; font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;What I have done here its, first pushed the apk to sdcard, opened the adb shell, logged in as root, mounted the system partition as read/write, renamed the original file to keep a backup and then copied the new file from sd card to the original file's path, them changed the&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #111111;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;permissions&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #111111; line-height: 19px;"&gt;&amp;nbsp;as needed, and remounted the file system as read only and then exited.&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="color: #111111; line-height: 19px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: #111111; line-height: 19px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;I will update a screen shot, to show that all of market applications which use to use some crap icon tiles now use the system icon tiles and the UI looks pretty good, and I feel its much much better than before. Only problem is that the way it chooses background is still random, and every time you restart the icon tiles would change. :)&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-3751048175976917376?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/3751048175976917376/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/customize-icon-tiles-for-galaxy-sl.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3751048175976917376'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3751048175976917376'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/customize-icon-tiles-for-galaxy-sl.html' title='Customize Icon Tiles for Galaxy SL i9003'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/-2gwvGuqXV7c/ToCU5LnJH_I/AAAAAAAAHHQ/8dy0mTcAbO8/s72-c/snap20110926_203214.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-7010534906705374093</id><published>2011-09-19T23:02:00.000-07:00</published><updated>2011-09-19T23:03:01.169-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux kernel'/><category scheme='http://www.blogger.com/atom/ns#' term='busybox'/><category scheme='http://www.blogger.com/atom/ns#' term='ADB'/><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><title type='text'>Install Busybox on Samsung i9003 Galaxy SL</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;First of all let me tell me if&amp;nbsp;busy box&amp;nbsp;is needed for you. Mostly it is needed because the adb shell does not have most of the commands supported such cp (copy), and it makes it difficult when you want to modify something (if you have rooted already) difficult because of&amp;nbsp;unavailability&amp;nbsp;of the commands support. So it is preferred to have&amp;nbsp;Busy box, which has most of the command support, and if you had worked in Linux you would know what is busy box for.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/-H6UEd_IkJUM/Tngl8pFIyFI/AAAAAAAAHHA/its60zMZ5WQ/s1600/busybox_installer.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em; text-align: justify;"&gt;&lt;img border="0" height="225" src="http://4.bp.blogspot.com/-H6UEd_IkJUM/Tngl8pFIyFI/AAAAAAAAHHA/its60zMZ5WQ/s320/busybox_installer.png" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Usually, you need to copy the busy box binary on to whichever folder you need, with the help of any command line tool, then say busybox --install, it should setup the links for all the commands and should work for you. And you may need to add that path into you PATH variable. Somehow after long search, I could not find any such thing working for me.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;But now that this application names 'busybox installer' does exactly the same, and it needs root permissions (to make it install in /system/xbin/ ) and you have the option to install any version of busybox you wish to.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;So my search ends here (somehow I had seen this before, and dint want to do it this way, wanted to do it manually). One you have installed it, it will automatically restart your phone. Now you have all the comands&amp;nbsp;available&amp;nbsp;on your phone when connected to adb. Some commands may still be taken from old toolbox, and if you specifically need busy box one, you can override it by typing busybox before it.&amp;nbsp;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-7010534906705374093?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/7010534906705374093/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/install-busybox-on-samsung-i9003-galaxy.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7010534906705374093'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7010534906705374093'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/install-busybox-on-samsung-i9003-galaxy.html' title='Install Busybox on Samsung i9003 Galaxy SL'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/-H6UEd_IkJUM/Tngl8pFIyFI/AAAAAAAAHHA/its60zMZ5WQ/s72-c/busybox_installer.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-3898960868009229826</id><published>2011-09-19T01:38:00.000-07:00</published><updated>2011-09-25T00:59:02.449-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Samsung'/><category scheme='http://www.blogger.com/atom/ns#' term='Galaxy SL'/><category scheme='http://www.blogger.com/atom/ns#' term='TouchWiz4'/><category scheme='http://www.blogger.com/atom/ns#' term='i9003'/><title type='text'>Samsung Touch Wiz 4.0 Look and Feel</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;This post is dedicated for showing the Look and Feel of Touch Wiz 4.0 Running on Galaxy SL (i9003). If you follow my previous post,&amp;nbsp;absolutely&amp;nbsp;there are no bugs, no lags, and only&amp;nbsp;excitement !!&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Here are few screen captures for showing all the features&lt;/div&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-TOfdl4uSxTo/Tnb7twOQ4RI/AAAAAAAAHGs/NIWQyiCaM7s/s1600/snap20110919_134414.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://2.bp.blogspot.com/-TOfdl4uSxTo/Tnb7twOQ4RI/AAAAAAAAHGs/NIWQyiCaM7s/s320/snap20110919_134414.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;br /&gt;&lt;/div&gt;&amp;nbsp;Fig 1: Picture showing home screen, if you observe, you can add as many icons as you want in the dock below. And the look and feel of home icon is updated.&lt;br /&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-Q2iHsZ3WGc8/Tnb7vCwYHAI/AAAAAAAAHGw/cIASck_s5JE/s1600/snap20110919_134420.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://2.bp.blogspot.com/-Q2iHsZ3WGc8/Tnb7vCwYHAI/AAAAAAAAHGw/cIASck_s5JE/s320/snap20110919_134420.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;Fig 2 : Picture showing the app drawer, you can see that instead of black now you have the transparent screen, and icon tiles have been removed, in fact you have option to enable or disable the same&lt;/div&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-kQV9sKocmEg/Tnb7v1ScZ_I/AAAAAAAAHG0/JMnRYpE_7Ik/s1600/snap20110919_134538.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://2.bp.blogspot.com/-kQV9sKocmEg/Tnb7v1ScZ_I/AAAAAAAAHG0/JMnRYpE_7Ik/s320/snap20110919_134538.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&amp;nbsp;Fig 3 : Home screen widgets are more standardized and looks more like Galaxy S-II, I usually don't like widgets and only widget I use is weather bug.&lt;/div&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/--tBxwyeBMaI/Tnb7w1jRtgI/AAAAAAAAHG4/q3PAfNAixWc/s1600/snap20110919_134715.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://4.bp.blogspot.com/--tBxwyeBMaI/Tnb7w1jRtgI/AAAAAAAAHG4/q3PAfNAixWc/s320/snap20110919_134715.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;Fig 4: Wallpaper options are more neat and clean, and it looks much better as show above.&lt;br /&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/-Ycj-KjEXRQY/Tnb7yXu4NYI/AAAAAAAAHG8/5oAje3Jzxu0/s1600/snap20110919_134729.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://1.bp.blogspot.com/-Ycj-KjEXRQY/Tnb7yXu4NYI/AAAAAAAAHG8/5oAje3Jzxu0/s320/snap20110919_134729.png" width="192" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;Fig 5 : App drawer editing is also improved and you can specify the number of columns and rows and also the number of icons. The best part is if some one likes to have folders then that option is also allowed. There is unofficial version named as Touch WIz 4.5 also available in XDA which seems to be modified a lot, and so, I do not recommend, but it does have lot of other enhancements.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;The icon tiles can be enabled to have backdrops for each icon, but it seems to be randomly picking the tiles from somewhere. I myself have opened the apk file in 7zip and see that most of the apps have well defined backdrops/tiles, but the TouchWiz 4.0 is messing up with it, and seems to be mismatch when it picks the icon tiles, so you may not be very impressed with icon tiles, you may have to live with it. I absolutely have no idea how they are picking the icon tiles at this point, if someone knows and why it behaves like this please do let me know.&lt;/div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-3898960868009229826?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/3898960868009229826/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/samsung-touch-wiz-40-look-and-feel.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3898960868009229826'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3898960868009229826'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/samsung-touch-wiz-40-look-and-feel.html' title='Samsung Touch Wiz 4.0 Look and Feel'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/-TOfdl4uSxTo/Tnb7twOQ4RI/AAAAAAAAHGs/NIWQyiCaM7s/s72-c/snap20110919_134414.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-2340512240078209227</id><published>2011-09-18T23:09:00.000-07:00</published><updated>2011-09-18T23:09:38.287-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Putty'/><category scheme='http://www.blogger.com/atom/ns#' term='ADB'/><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><category scheme='http://www.blogger.com/atom/ns#' term='debugging'/><category scheme='http://www.blogger.com/atom/ns#' term='Android Debug Bridge'/><title type='text'>Replace ADB Shell With Putty</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;If your phone is rooted, you need ADB (Android Debug Bridge) for accessing the phone over command line. And when on Windows you may not be&amp;nbsp;comfortable&amp;nbsp;running the Linux command prompt on Windows. You can always run a telnet server on your android phone, and connect using the Putty, but this needs lot of work, and its not an easy option.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;There is an easy option with the help of ADB, you need to have a modified Putty for this, which has the ADB connection type to choose from, and then you can use Putty as you normally use to.&amp;nbsp;Thanks for senior XDA member sztupy. sztupy has compiled a Putty binary with most of the settings pre-set. Here is a snap shot of the same for your reference.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: Arial, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: 14px; line-height: 22px;"&gt;&lt;img alt="image" src="http://cloud.addictivetips.com/wp-content/uploads/2010/11/image57.png" /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: Arial, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: 14px; line-height: 22px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="line-height: 22px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;All you need to do is to set the host name to 'transport-usb' as shown and if port number did not come automatically set it to '5037' and you are done.&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="line-height: 22px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="line-height: 22px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Connect the phone using usb cable ans set the debugging mode on, as you normally do to use with ADB, you can enjoy the familiar Putty interface.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: Arial, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: 14px; line-height: 22px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-2340512240078209227?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/2340512240078209227/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/replace-adb-shell-with-putty.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2340512240078209227'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2340512240078209227'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/replace-adb-shell-with-putty.html' title='Replace ADB Shell With Putty'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-3946763157835037241</id><published>2011-09-18T07:45:00.000-07:00</published><updated>2011-09-18T07:45:51.966-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ShareApp Fix'/><category scheme='http://www.blogger.com/atom/ns#' term='Samsung'/><category scheme='http://www.blogger.com/atom/ns#' term='Galaxy SL'/><category scheme='http://www.blogger.com/atom/ns#' term='TouchWiz4'/><category scheme='http://www.blogger.com/atom/ns#' term='Android 2.3.4'/><category scheme='http://www.blogger.com/atom/ns#' term='i9003'/><title type='text'>Install Samsung TouchWiz 4.0 for Galaxy SL i9003</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;&lt;a href="http://forum.xda-developers.com/attachment.php?attachmentid=619933&amp;amp;stc=1&amp;amp;d=1307601200" imageanchor="1" style="clear: right; float: right; margin-bottom: 1em; margin-left: 1em;"&gt;&lt;img border="0" height="320" src="http://forum.xda-developers.com/attachment.php?attachmentid=619933&amp;amp;stc=1&amp;amp;d=1307601200" width="192" /&gt;&lt;/a&gt;&lt;a href="http://forum.xda-developers.com/attachment.php?attachmentid=619934&amp;amp;stc=1&amp;amp;d=1307601200" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://forum.xda-developers.com/attachment.php?attachmentid=619934&amp;amp;stc=1&amp;amp;d=1307601200" width="192" /&gt;&lt;/a&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;If you have updated to the Gingerbread 2.3.4 and rooted by following posts on my phone, then you would see that there is not much cosmetic changes done to the User Interface, except for the status bar battery icons etc. The easiest way is to update to a new UI is to install any other&amp;nbsp;launcher&amp;nbsp;such as &lt;b&gt;Go Launcher. &lt;/b&gt;In fact Go Launcher Ex is very powerful, and it has most of the features you would look for in your phone, and also many themes are available for download. As a second launcher I would a&lt;/span&gt;lways have it on my phone, in case the primary one fails after some updates etc.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;But the battery consumption seems to be very high, may be because of the visual effects. The main reason I wanted to update to new UI theme is that, with Galaxy S2, Samsung had get rid of that icon tiles which would give an iPhone type look. But sometimes the choice of wrong color for the tile makes it look very boring, and some how I am bored with it, and want to get rid of it.&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;So, I come across&lt;a href="http://forum.xda-developers.com/showthread.php?t=1116599"&gt; this link on XDA,&lt;/a&gt; and he has given the TouchWiz 4.0 Launcher apk, which is working fine with my Galaxy SL, and I have obsolutely no issues with it. Few of the Widgets does not work with it, especially the Samsung ones and mostly you don't need them at all, so you can delete them get rid of it.&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;The install process is very simple,&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;ul style="text-align: left;"&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Copy it to SD card via ADB or any other method.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Use ADB connection, and login as root.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Mount the /system/ as RW&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;There will be TouchWiz30Launcher.apk and TouchWiz30Launcher.odex files, make a back up of them incase if something goes wrong.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Replace the TouchWiz30Launcher.apk with the new one downloaded.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;You need to place the lib file inside the /system/lib folder&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Use cat source &amp;gt; destination as cp command does not work&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Now that most of things work except for Samsung Widgets, There is an Share button when you edit the app drawer, which would cause a force close, you need to fix this.&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Download the &lt;a href="http://forum.xda-developers.com/attachment.php?attachmentid=625293&amp;amp;d=1308077457"&gt;ShareApp.apk from here&lt;/a&gt;, and place it in the /system/app/ folder following the same method mentioned above.&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;You are DONE, you would have a fully running, low battery consuming Samsung Touch Wiz 4.0 ready on your phone, Enjoy.&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;The&amp;nbsp;Benefits&amp;nbsp;are as below.&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;b&gt;For appdrawer:&lt;/b&gt;&lt;/span&gt;&lt;div&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;column count&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;item count per page&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;free sort mode / alphabetical sort&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;enable/disable colored tile&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: #111111;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;&lt;div&gt;&lt;b&gt;For Home screen:&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;enable Landscape mode (if you change from off to on -&amp;gt; needs a reboot to take effect)&lt;/li&gt;&lt;li&gt;use big page indicator icons&lt;/li&gt;&lt;li&gt;whether to show the App names&lt;/li&gt;&lt;li&gt;uninstall apps from home screen [on/off]&lt;/li&gt;&lt;li&gt;page indicator icon fades off after swiping [on/off]&lt;/li&gt;&lt;li&gt;amount of rows on home screen&lt;/li&gt;&lt;li&gt;screen count-defaultscreen (starts at 0)&lt;/li&gt;&lt;li&gt;amount of icons in dock (not tested with higher numbers then 5)&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-3946763157835037241?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/3946763157835037241/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/install-samsung-touchwiz-40-for-galaxy.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3946763157835037241'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3946763157835037241'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/install-samsung-touchwiz-40-for-galaxy.html' title='Install Samsung TouchWiz 4.0 for Galaxy SL i9003'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-4199517558418777956</id><published>2011-09-16T01:45:00.000-07:00</published><updated>2011-09-16T01:45:17.382-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cloud'/><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><category scheme='http://www.blogger.com/atom/ns#' term='Google Music'/><title type='text'>Google Music Beta on Android</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-H4aSlTGLL4E/TnML64CQb6I/AAAAAAAAHGk/az838q2zRCc/s1600/music_beta.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em; text-align: justify;"&gt;&lt;img border="0" src="http://2.bp.blogspot.com/-H4aSlTGLL4E/TnML64CQb6I/AAAAAAAAHGk/az838q2zRCc/s1600/music_beta.png" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;You might have heard that Google had launched the music beta service, which is similar to the other Google service which is linked to your Google account, but only limitation as of now is that it is available on in the United States, and it also says that its free for limited period of time. May be only till the beta testing is complete, but I hope to have it continued after that. You can store about 20,000 songs to your account and they will be stored in cloud, so that it can be accessed from any device, such as TAB or Android Phone. You can carry your music collection where ever you go, sound impressive huh? why don't you get one?&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;All you need is an US proxy and log into your Google account from the proxy server or VPN and request for one, or if you have a friend who can send invite ask him to send one. So you would get the invite in few days if you have requested for one.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;After the invite is received you can download the music manager from &lt;u&gt;music.google.com&lt;/u&gt; and install it.&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;ul style="text-align: left;"&gt;&lt;li style="text-align: justify;"&gt;Make sure you keep all your tag information for the songs updated before uploading using Google Music Manager, otherwise it becomes a mess later to organize your music. Google music would organize your music based on the tag information.&lt;/li&gt;&lt;li style="text-align: justify;"&gt;Also make sure that you use the folder upload option rather than windows media player library sync, because mostly if you have updated the tag information recently, it seems to be not working fine.&amp;nbsp;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;Anyways, follow which ever method, but upload the music, but one thing to remember, while uploading you don't need to be in VPN, and sometimes with VPN, if corporate it will not work.&lt;/li&gt;&lt;/ul&gt;&lt;div style="text-align: left;"&gt;&lt;a href="http://4.bp.blogspot.com/-QUywVxtVsFc/TnMMCCL42RI/AAAAAAAAHGo/u89AkRdvTm0/s1600/Google-Music-Beta.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em; text-align: justify;"&gt;&lt;img border="0" height="240" src="http://4.bp.blogspot.com/-QUywVxtVsFc/TnMMCCL42RI/AAAAAAAAHGo/u89AkRdvTm0/s320/Google-Music-Beta.jpg" width="320" /&gt;&lt;/a&gt;&lt;div style="text-align: justify;"&gt;Now you need android application to use the same music on your android device, but if you are not in US, then the market wont allow you to install from there, even though it is free application. So you need to &lt;a href="https://docs.google.com/uc?id=0B_XE3ZcVmItDODE4ZTdlMTgtMGRkZC00NTJkLTk1YTAtY2Y2ZDNkYzM1MzI0&amp;amp;export=download&amp;amp;hl=en"&gt;download it from here&lt;/a&gt;, and install using any other method, such as copy to SD card then install by enabling non market application installation in settings.&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Once you have installed fortunately, it does not need a VPN to play your music, you can be in any country, Wifi/3G/EDGE/GPRS, it can play the music for you.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-4199517558418777956?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/4199517558418777956/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/google-music-beta-on-android.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4199517558418777956'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4199517558418777956'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/google-music-beta-on-android.html' title='Google Music Beta on Android'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/-H4aSlTGLL4E/TnML64CQb6I/AAAAAAAAHGk/az838q2zRCc/s72-c/music_beta.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-759622512376534676</id><published>2011-09-15T23:22:00.000-07:00</published><updated>2011-09-15T23:24:13.224-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='XXKPH'/><category scheme='http://www.blogger.com/atom/ns#' term='Gingerbreak'/><category scheme='http://www.blogger.com/atom/ns#' term='Gingerbread'/><category scheme='http://www.blogger.com/atom/ns#' term='Galaxy SL'/><category scheme='http://www.blogger.com/atom/ns#' term='Root'/><category scheme='http://www.blogger.com/atom/ns#' term='Android Apps'/><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><category scheme='http://www.blogger.com/atom/ns#' term='Android 2.3.4'/><category scheme='http://www.blogger.com/atom/ns#' term='i9003'/><title type='text'>Root Samsung Galaxy SL (i9003) Gingerbread 2.3.4 (XXKPH)</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;I had hard time finding how to root the Samsung Galaxy SL, 2.3.4, XXPKH. There were many blogs and website talking about rooting, but because XXKPH was the latest version and it was 2.3.4, most of the methods mentioned in there does not work.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;The most basic method is to use the SOC (Super One Click) and it does not work with XXKPH, because the kernel exploit cannot be done by Ginger break, and it seems they have closed the loophole which&amp;nbsp;ginger break&amp;nbsp;was using. The original Ginger break method was mentioned in this&lt;a href="http://c-skills.blogspot.com/2011/04/yummy-yummy-gingerbreak.html"&gt; website&lt;/a&gt;, and he has clearly mentioned that it has to be using the usb debugging mode on adb. SOC also uses the same method, and it should be the only way to do it.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Now how do we proceed, I read in a&amp;nbsp;Spanish&amp;nbsp;website for i9000 that the kernel must be replaced with a kernel which can be exploited and then exploit using SOC and replace back the original kernel after installing SU (super user app). I found it something&amp;nbsp;convincing&amp;nbsp;and then tried the &lt;a href="http://forum.xda-developers.com/showthread.php?t=1191623"&gt;method on XDA developer&lt;/a&gt; where he talks about flashing the fixed binary and then normal boot again. I was scared to try this before as I do not want to use any modified binary as the XXKPH is very stable, and battery life and GPS are working awesome for me. Any change would only deteriorate the&amp;nbsp;performance, as these people may have done somethign which they are not very sure of.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;b&gt;Here goes the method for XXKPH&lt;/b&gt;&lt;/div&gt;&lt;ul style="text-align: left;"&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;After Flashing to new Firmware , Go to Downloading Mode By pressing volume down + menu button + power button and Flash the Phone Using the PDA file &lt;i&gt;GT-I9003_PDA_XXKPE-fixed.tar&lt;/i&gt;&lt;/span&gt;&lt;/li&gt;&lt;ul&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;a href="http://forum.xda-developers.com/attachment.php?attachmentid=672090&amp;amp;d=1312101664" rel="nofollow" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #b35400; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none;" target="_blank"&gt;GT-I9003_PDA-XXKPE-fixed.tar&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;Root USing SOC (Latest version of SOC can be downloaded from &lt;a href="http://forum.xda-developers.com/showthread.php?t=803682"&gt;here&lt;/a&gt;)&lt;/span&gt;&lt;/li&gt;&lt;ul&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;While rooting, you may find that it it stuck at step #6, may be you can disconnect the cable and connect back, and it should do the trick !! (happened with me)&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; line-height: 19px;"&gt;&lt;span class="Apple-style-span" style="color: #111111;"&gt;Flash PDA with the normalboot.img.tar attached below&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;ul&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;a href="http://forum.xda-developers.com/showpost.php?p=16737945&amp;amp;postcount=146" rel="nofollow" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #b35400; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none;" target="_blank"&gt;http://forum.xda-developers.com/show...&amp;amp;postcount=146&lt;/a&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/ul&gt;&lt;div style="text-align: justify;"&gt;&lt;b&gt;Note:&amp;nbsp;&lt;/b&gt;With the absolutely beautiful ADB exploit I use, titled rageagainstthecage (ratc), absolute ALL devices can be rooted. This is because it exploit is ADB which all devices use. There is an issue though. Some devices have a NAND lock which does not allow you to write to the /system mount. Because of this, you can't copy su, sqlite or busybox to /system/bin. This creates some issues but there is a work around. For things that don't need access to /system (like enabling non-market apps) I can use the ratc exploit to make those changes. If your device cannot use su in /system/bin then you can simple select a checkbox (as of v1.5) that says to use ratc.&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;There are 3 levels of "root" we can define:&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;Level 1: Shell Root (with ratc rooting the adb shell but no /system write access)&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;Level 2: Temporary Root (/system/bin/su installed but lost on reboot)&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;Level 3: Full Root (/system/bin/su installed and sticks)&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;Some devices have a NAND lock. SuperOneClick will only give a Shell root until you remove this lock.&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;Gingerbreak uses rageagainstthecage, &amp;nbsp;is a root exploit via a fork bomb. Some antivirus program may raise alert for malicious content while unzipping, and here is the explanation for it.&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; border-collapse: separate; color: black; font-style: normal; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;It IS a potentially malicious payload, BUT it is being used with owner's consent to root the phone.&amp;nbsp;The DreamDroid malware use exactly same payload - they are trojans, but this is a helpful tool.&amp;nbsp;It IS a dangerous tool in the wrong hands, but this is a root exploit, so you should exercise common sense and a little understanding of what it does and how it works.&lt;/span&gt;&lt;/div&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-759622512376534676?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/759622512376534676/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/root-samsung-galaxy-sl-i9003.html#comment-form' title='12 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/759622512376534676'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/759622512376534676'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/root-samsung-galaxy-sl-i9003.html' title='Root Samsung Galaxy SL (i9003) Gingerbread 2.3.4 (XXKPH)'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>12</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-7617199320607959595</id><published>2011-09-13T03:27:00.000-07:00</published><updated>2011-09-13T22:35:06.173-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='XXKPH'/><category scheme='http://www.blogger.com/atom/ns#' term='Gingerbread'/><category scheme='http://www.blogger.com/atom/ns#' term='Galaxy SL'/><category scheme='http://www.blogger.com/atom/ns#' term='Android 2.3.4'/><category scheme='http://www.blogger.com/atom/ns#' term='i9003'/><title type='text'>Update Galaxy SL (i9003) to Gingerbread 2.3.4</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;I followed the procedure from &lt;a href="http://forum.xda-developers.com/showthread.php?t=1133787"&gt;here&lt;/a&gt;. Out of all the guides out there, which are most confusing this is the best one I have ever come across. He is clear and straight forward of what you have to do, and small guide, not to get confused with lengthy ones.&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;I am copy pasting it here for your reference, may be for my reference later, as I am not interested with all of it.&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;img alt="" border="0" src="http://i285.photobucket.com/albums/ll41/gerrie_gie/Android/Gingerbread.png" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4;"&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4; color: #111111; line-height: 19px;"&gt;&lt;img alt="" border="0" src="http://i285.photobucket.com/albums/ll41/gerrie_gie/Android/Latest.png" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="color: #111111; line-height: 19px;"&gt;&lt;span class="Apple-style-span" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-color: initial; border-style: initial; outline-color: initial; outline-style: initial;"&gt;&lt;img alt="" border="0" src="http://i285.photobucket.com/albums/ll41/gerrie_gie/XXKPH.png" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;b style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #111111; line-height: 19px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;b style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #111111; line-height: 19px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Note: XXKPH can only be flashed with help from it's supporting predecessor XXKPE, So make sure you have XXKPE downloaded. User flashing version varies with this, but this is my successful 100% assured boot.&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="background-color: #fbf8f4;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;ol style="color: #111111; line-height: 19px; text-align: left;"&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Firstly, Download the link from spacebar's XXKPH Feedback thread.&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Run Odin3 v1.83&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Set your phone to download mode : Press Volume down + OK first, then hold Power button.&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Connect your phone, you should see Odin shows your phone is Added with COM number.&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Click PIT button and select this file: latona_20110114.pit&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;You should see Re-Partition, Auto Reboot and F. Reset Time checked.&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Click PDA button and select this file: CODE_I9003XXKPE_CL409735_REV08_user_low_ship.tar&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Click PHONE button and select this file: MODEM_I9003XXKPE_REV_00_CL1041909.tar&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Click BOOTLOADER button and select this file: APBOOT_I9003XXKPE_CL409735_REV08_user_low_ship.tar&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Click CSC button and select this file: GT-I9003-CSC-MULTI-OXAKPE.tar&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Click Start button to flash these files to phone.&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Do not touch anything till you see PASS on the program window.&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;div style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Turn off the phone and set it back into download mode once you get an initial first boot to homescreen. Do not set up anything, Just power off and set to download mode.&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Note: You only need to flash once to XXKPE before proceeding to XXKPH&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;In Odin, press Reset button. Re-partition should be unchecked automatically.&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Select file I9003XXKPH_I9003XXKPH_I9003SERKPH_HOME.tar as PDA&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Click on Start to flash XXKPH PDA to phone&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Once you have flashed, after the phone started up, press *#1234# and check your PDA,Phone and CSC, everything should ended with KPH&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Factory reset and enjoy&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;div style="color: #111111; line-height: 19px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;b&gt;Feedback: &lt;/b&gt;These is my experience and it may differ.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: #111111; line-height: 19px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: #111111; line-height: 19px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;I had updated for KB2 Indian version. I flashed first XXKPE as suggested by the guide, and then XXKPH.&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;ol style="text-align: left;"&gt;&lt;li style="color: #111111; line-height: 19px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Now the battery life seem to have increased, I am not very sure about it, but feels like, my phone use to always crib low battery, and not it does not happen. I hardly put on charging these days :)&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="color: #111111; line-height: 19px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;No overheating etc, as some might have wrongly mentioned, but as far as I know this is official release for Russia so such issues can't be there&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="color: #111111; line-height: 19px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;All peripherals and system functions such as wifi, camera everything works fine.&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="color: #111111; line-height: 19px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;The GPS works like charm, and it has been fixed, it locks within 5 seconds and you are connected.&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="color: #111111; line-height: 19px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;There are three new apps&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;ul&gt;&lt;li style="color: #111111; line-height: 19px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Samsung Navigation Route 66 - which seems promising, it has information about the city, so easy to search and navigate.&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="color: #111111; line-height: 19px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;Publication Reader - You can put your paper/magazine subscriptions and can be read offline.&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="color: #111111; line-height: 19px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;There is a short cut to downloads which was much needed and was missing in previous version&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;span class="Apple-style-span" style="color: #111111;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;Not many&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #111111;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;cosmetic&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #111111;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;&amp;nbsp;changes compared to 2.2 Froyo, it's all the same look and feel. The boot animation music has changed, I felt previous one was better.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;span class="Apple-style-span" style="color: #111111;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;Performance has not changed much, it's almost same, may be little better I could say.&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;span class="Apple-style-span" style="color: #111111;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;Last, but not the least Gmail video chat is something which is expected in 2.3.4 and it does not present in this, and for this you need to root and install the apk from outside, but as of now no good rooting available for 2.3.4, and whatever present seem to be not working.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;span class="Apple-style-span" style="color: #111111;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;So if you have problem with battery life, then only update, else no need, and don't wait for gmail video chat support to come, I&amp;nbsp;don't&amp;nbsp;think it would ever come on SL&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;span class="Apple-style-span" style="color: #111111;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;Note: All the binaries needed can be downloaded from &lt;a href="http://forum.xda-developers.com/showthread.php?p=12310841#post12310841"&gt;here&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;span class="Apple-style-span" style="color: #111111;"&gt;&lt;a href="http://forum.xda-developers.com/showthread.php?p=12310841#post12310841"&gt;http://forum.xda-developers.com/showthread.php?p=12310841#post12310841&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-7617199320607959595?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/7617199320607959595/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/update-galaxy-sl-i9003-to-gingerbread.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7617199320607959595'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7617199320607959595'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/09/update-galaxy-sl-i9003-to-gingerbread.html' title='Update Galaxy SL (i9003) to Gingerbread 2.3.4'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://i285.photobucket.com/albums/ll41/gerrie_gie/Android/th_Gingerbread.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-6222893789456438084</id><published>2011-07-25T07:36:00.001-07:00</published><updated>2011-07-26T03:01:22.986-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='c++'/><category scheme='http://www.blogger.com/atom/ns#' term='typecast'/><category scheme='http://www.blogger.com/atom/ns#' term='Andorid-x86'/><category scheme='http://www.blogger.com/atom/ns#' term='reinterpret cast'/><category scheme='http://www.blogger.com/atom/ns#' term='const cast'/><category scheme='http://www.blogger.com/atom/ns#' term='dynamic cast'/><category scheme='http://www.blogger.com/atom/ns#' term='typeid'/><category scheme='http://www.blogger.com/atom/ns#' term='static cast'/><title type='text'>Type Casting in C++</title><content type='html'>&lt;p align="justify"&gt;Converting an expression of a given type into another type is known as type-casting. We have already seen some ways to type cast:&lt;br&gt;&lt;br&gt;&lt;strong&gt;Implicit Conversion&lt;br&gt;&lt;br&gt;&lt;/strong&gt;Implicit conversions do not require any operator. They are automatically performed when a value is copied to a compatible type. For example:&lt;/p&gt; &lt;div align="justify"&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;short a=2000;&lt;br /&gt;int b;&lt;br /&gt;b=a;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;br /&gt;&lt;p align="justify"&gt;Here, the value of a has been promoted from short to int and we have not had to specify any type-casting operator. This is known as a standard conversion. Standard conversions affect fundamental data types, and allow conversions such as the conversions between numerical types (short to int, int to float, double to int...), to or from bool, and some pointer conversions. Some of these conversions may imply a loss of precision, which the compiler can signal with a warning. This can be avoided with an explicit conversion.&lt;br&gt;&lt;br&gt;Implicit conversions also include constructor or operator conversions, which affect classes that include specific constructors or operator functions to perform conversions. For example:&lt;/p&gt;&lt;br /&gt;&lt;div align="justify"&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;class A {};&lt;br /&gt;class B { public: B (A a) {} };&lt;br /&gt;&lt;br /&gt;A a;&lt;br /&gt;B b=a;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;br /&gt;&lt;div align="justify"&gt;Here, a implicit conversion happened between objects of class A and class B, because B has a constructor that takes an object of class A as parameter. Therefore implicit conversions from A to B are allowed. &lt;br&gt;&lt;br&gt;&lt;strong&gt;Explicit Conversion&lt;br&gt;&lt;br&gt;&lt;/strong&gt;C++ is a strong-typed language. Many conversions, specially those that imply a different interpretation of the value, require an explicit conversion. We have already seen two notations for explicit type conversion: functional and c-like casting:&lt;/div&gt;&lt;br /&gt;&lt;div align="justify"&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;short a=2000;&lt;br /&gt;int b;&lt;br /&gt;b = (int) a;    // c-like cast notation&lt;br /&gt;b = int (a);    // functional notation&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;br /&gt;&lt;div align="justify"&gt;The functionality of these explicit conversion operators is enough for most needs with fundamental data types. However, these operators can be applied indiscriminately on classes and pointers to classes, which can lead to code that while being syntactically correct can cause runtime errors. For example, the following code is syntactically correct:&lt;/div&gt;&lt;br /&gt;&lt;div align="justify"&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;// class type-casting&lt;br /&gt;#include &amp;lt;iostream&amp;gt;using namespace std;&lt;br /&gt;&lt;br /&gt;class CDummy {&lt;br /&gt;    float i,j;&lt;br /&gt;};&lt;br /&gt;&lt;br /&gt;class CAddition {&lt;br /&gt;        int x,y;&lt;br /&gt;  public:&lt;br /&gt;        CAddition (int a, int b) { x=a; y=b; }&lt;br /&gt;        int result() { return x+y;}&lt;br /&gt;};&lt;br /&gt;&lt;br /&gt;int main () {&lt;br /&gt;  CDummy d;&lt;br /&gt;  CAddition * padd;&lt;br /&gt;  padd = (CAddition*) &amp;amp;d;&lt;br /&gt;  cout &amp;lt;&amp;lt; padd-&amp;gt;result();&lt;br /&gt;  return 0;&lt;br /&gt;}&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;br /&gt;&lt;div align="justify"&gt;The program declares a pointer to CAddition, but then it assigns to it a reference to an object of another incompatible type using explicit type-casting: &lt;br&gt;&lt;br&gt;padd = (CAddition*) &amp;amp;d;&lt;br&gt;&lt;br&gt;Traditional explicit type-casting allows to convert any pointer into any other pointer type, independently of the types they point to. The subsequent call to member result will produce either a run-time error or a unexpected result.&lt;br&gt;&lt;br&gt;In order to control these types of conversions between classes, we have four specific casting operators: dynamic_cast, reinterpret_cast, static_cast and const_cast. Their format is to follow the new type enclosed between angle-brackets (&amp;lt;&amp;gt;) and immediately after, the expression to be converted between parentheses.&lt;br&gt;&lt;br&gt;dynamic_cast &amp;lt;new_type&amp;gt; (expression)&lt;br&gt;reinterpret_cast &amp;lt;new_type&amp;gt; (expression)&lt;br&gt;static_cast &amp;lt;new_type&amp;gt; (expression)&lt;br&gt;const_cast &amp;lt;new_type&amp;gt; (expression) &lt;br&gt;&lt;br&gt;The traditional type-casting equivalents to these expressions would be:&lt;br&gt;&lt;br&gt;(new_type) expression&lt;br&gt;new_type (expression)&lt;br&gt;&lt;br&gt;but each one with its own special characteristics:&lt;br&gt;&lt;br&gt;&lt;strong&gt;Dynamic Cast&lt;br&gt;&lt;br&gt;&lt;/strong&gt;&lt;font face="Arial"&gt;&lt;font style="font-weight: normal"&gt;dynamic cast can be used only with pointers and references to objects. Its purpose is to ensure that the result of the type conversion is a valid complete object of the requested class.&lt;br&gt;&lt;br&gt;&lt;/font&gt;&lt;font style="font-weight: normal"&gt;Therefore, &lt;/font&gt;&lt;tt&gt;&lt;font style="font-weight: normal"&gt;dynamic_cast&lt;/font&gt;&lt;/tt&gt;&lt;font style="font-weight: normal"&gt; is always successful when we cast a class to one of its base classes:&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;&lt;br /&gt;&lt;div align="justify"&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;class CBase { };&lt;br /&gt;class CDerived: public CBase { };&lt;br /&gt;&lt;br /&gt;CBase b; CBase* pb;&lt;br /&gt;CDerived d; CDerived* pd;&lt;br /&gt;&lt;br /&gt;pb = dynamic_cast&amp;lt;CBase*&amp;gt;(&amp;amp;d);     // ok: derived-to-base&lt;br /&gt;pd = dynamic_cast&amp;lt;CDerived*&amp;gt;(&amp;amp;b);  // wrong: base-to-derived&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;br /&gt;&lt;p align="justify"&gt;The second conversion in this piece of code would produce a compilation error since base-to-derived conversions are not allowed with &lt;tt&gt;dynamic_cast&lt;/tt&gt; unless the base class is polymorphic.&lt;br&gt;&lt;br&gt;When a class is polymorphic, &lt;tt&gt;dynamic_cast&lt;/tt&gt; performs a special checking during runtime to ensure that the expression yields a valid complete object of the requested class:&lt;/p&gt;&lt;br /&gt;&lt;div align="justify"&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;// dynamic_cast&lt;br /&gt;#include &amp;lt;iostream&amp;gt;#include &amp;lt;exception&amp;gt;using namespace std;&lt;br /&gt;&lt;br /&gt;class CBase { virtual void dummy() {} };&lt;br /&gt;class CDerived: public CBase { int a; };&lt;br /&gt;&lt;br /&gt;int main () {&lt;br /&gt;  try {&lt;br /&gt;    CBase * pba = new CDerived;&lt;br /&gt;    CBase * pbb = new CBase;&lt;br /&gt;    CDerived * pd;&lt;br /&gt;&lt;br /&gt;    pd = dynamic_cast&amp;lt;CDerived*&amp;gt;(pba);&lt;br /&gt;    if (pd==0) cout &amp;lt;&amp;lt; "Null pointer on first type-cast" &amp;lt;&amp;lt; endl;&lt;br /&gt;&lt;br /&gt;    pd = dynamic_cast&amp;lt;CDerived*&amp;gt;(pbb);&lt;br /&gt;    if (pd==0) cout &amp;lt;&amp;lt; "Null pointer on second type-cast" &amp;lt;&amp;lt; endl;&lt;br /&gt;&lt;br /&gt;  } catch (exception&amp;amp; e) {cout &amp;lt;&amp;lt; "Exception: " &amp;lt;&amp;lt; e.what();}&lt;br /&gt;  return 0;&lt;br /&gt;}&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;br /&gt;&lt;p align="justify"&gt;&lt;b&gt;Compatibility note:&lt;/b&gt; &lt;br&gt;&lt;tt&gt;&lt;br&gt;dynamic_cast&lt;/tt&gt; requires the Run-Time Type Information (RTTI) to keep track of dynamic types. Some compilers support this feature as an option which is disabled by default. This must be enabled for runtime type checking using &lt;tt&gt;dynamic_cast&lt;/tt&gt; to work properly.&lt;br&gt;&lt;br&gt;The code tries to perform two dynamic casts from pointer objects of type &lt;tt&gt;CBase*&lt;/tt&gt; (&lt;tt&gt;pba&lt;/tt&gt; and &lt;tt&gt;pbb&lt;/tt&gt;) to a pointer object of type &lt;tt&gt;CDerived*&lt;/tt&gt;, but only the first one is successful. Notice their respective initializations: &lt;br&gt;&lt;br&gt;&lt;code&gt;CBase * pba = &lt;var&gt;new&lt;/var&gt; CDerived;&lt;br&gt;CBase * pbb = &lt;var&gt;new&lt;/var&gt; CBase;&lt;br&gt;&lt;br&gt;&lt;/code&gt;Even though both are pointers of type &lt;tt&gt;CBase*&lt;/tt&gt;, &lt;tt&gt;pba&lt;/tt&gt; points to an object of type &lt;tt&gt;CDerived&lt;/tt&gt;, while &lt;tt&gt;pbb&lt;/tt&gt; points to an object of type &lt;tt&gt;CBase&lt;/tt&gt;. Thus, when their respective type-castings are performed using &lt;tt&gt;dynamic_cast&lt;/tt&gt;, &lt;tt&gt;pba&lt;/tt&gt; is pointing to a full object of class &lt;tt&gt;CDerived&lt;/tt&gt;, whereas &lt;tt&gt;pbb&lt;/tt&gt; is pointing to an object of class &lt;tt&gt;CBase&lt;/tt&gt;, which is an incomplete object of class &lt;tt&gt;CDerived&lt;/tt&gt;.&lt;br&gt;&lt;br&gt;When &lt;tt&gt;dynamic_cast&lt;/tt&gt; cannot cast a pointer because it is not a complete object of the required class -as in the second conversion in the previous example- it returns a null pointer to indicate the failure. If &lt;tt&gt;dynamic_cast&lt;/tt&gt; is used to convert to a reference type and the conversion is not possible, an exception of type &lt;tt&gt;bad_cast&lt;/tt&gt; is thrown instead.&lt;br&gt;&lt;br&gt;&lt;tt&gt;dynamic_cast&lt;/tt&gt; can also cast null pointers even between pointers to unrelated classes, and can also cast pointers of any type to void pointers (&lt;tt&gt;void*&lt;/tt&gt;). &lt;br&gt;&lt;br&gt;&lt;strong&gt;static_cast&lt;/strong&gt;&lt;br&gt;&lt;br&gt;static_cast can perform conversions between pointers to related classes, not only from the derived class to its base, but also from a base class to its derived. This ensures that at least the classes are compatible if the proper object is converted, but no safety check is performed during runtime to check if the object being converted is in fact a full object of the destination type. Therefore, it is up to the programmer to ensure that the conversion is safe. On the other side, the overhead of the type-safety checks of dynamic_cast is avoided.&lt;/p&gt;&lt;br /&gt;&lt;div align="justify"&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;class CBase {};&lt;br /&gt;class CDerived: public CBase {};&lt;br /&gt;CBase * a = new CBase;&lt;br /&gt;CDerived * b = static_cast&amp;lt;CDerived*&amp;gt;(a);&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;br /&gt;&lt;p align="justify"&gt;This would be valid, although &lt;tt&gt;b&lt;/tt&gt; would point to an incomplete object of the class and could lead to runtime errors if dereferenced.&lt;br&gt;&lt;br&gt;&lt;tt&gt;static_cast&lt;/tt&gt; can also be used to perform any other non-pointer conversion that could also be performed implicitly, like for example standard conversion between fundamental types:&lt;br&gt;&lt;br&gt;&lt;code&gt;&lt;var&gt;double&lt;/var&gt; d=3.14159265;&lt;br&gt;&lt;var&gt;int&lt;/var&gt; i = &lt;var&gt;static_cast&lt;/var&gt;&amp;lt;&lt;var&gt;int&lt;/var&gt;&amp;gt;(d);&lt;br&gt;&lt;br&gt;&lt;/code&gt;Or any conversion between classes with explicit constructors or operator functions as described in "implicit conversions" above.&lt;br&gt;&lt;br&gt;&lt;strong&gt;reinterpret_cast&lt;/strong&gt;&lt;br&gt;&lt;br&gt;reinterpret_cast converts any pointer type to any other pointer type, even of unrelated classes. The operation result is a simple binary copy of the value from one pointer to the other. All pointer conversions are allowed: neither the content pointed nor the pointer type itself is checked.&lt;br&gt;&lt;br&gt;It can also cast pointers to or from integer types. The format in which this integer value represents a pointer is platform-specific. The only guarantee is that a pointer cast to an integer type large enough to fully contain it, is granted to be able to be cast back to a valid pointer.&lt;br&gt;&lt;br&gt;The conversions that can be performed by reinterpret_cast but not by static_cast have no specific uses in C++ are low-level operations, whose interpretation results in code which is generally system-specific, and thus non-portable. For example:&lt;/p&gt;&lt;br /&gt;&lt;div align="justify"&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;class A {};&lt;br /&gt;class B {};&lt;br /&gt;A * a = new A;&lt;br /&gt;B * b = reinterpret_cast&amp;lt;B*&amp;gt;(a);&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;br /&gt;&lt;p align="justify"&gt;This is valid C++ code, although it does not make much sense, since now we have a pointer that points to an object of an incompatible class, and thus dereferencing it is unsafe.&lt;br&gt;&lt;br&gt;&lt;strong&gt;const_cast&lt;br&gt;&lt;/strong&gt;&lt;br&gt;This type of casting manipulates the constness of an object, either to be set or to be removed. For example, in order to pass a const argument to a function that expects a non-constant parameter:&lt;/p&gt;&lt;br /&gt;&lt;div align="justify"&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;// const_cast&lt;br /&gt;#include &amp;lt;iostream&amp;gt;using namespace std;&lt;br /&gt;&lt;br /&gt;void print (char * str)&lt;br /&gt;{&lt;br /&gt;  cout &amp;lt;&amp;lt; str &amp;lt;&amp;lt; endl;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;int main () {&lt;br /&gt;  const char * c = "sample text";&lt;br /&gt;  print ( const_cast&amp;lt;char *&amp;gt; (c) );&lt;br /&gt;  return 0;&lt;br /&gt;}&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;br /&gt;&lt;p align="justify"&gt;&lt;strong&gt;typeid&lt;/strong&gt;&lt;br&gt;&lt;br&gt;typeid allows to check the type of an expression: &lt;br&gt;&lt;br&gt;typeid (expression)&lt;br&gt;&lt;br&gt;This operator returns a reference to a constant object of type type_info that is defined in the standard header file &amp;lt;typeinfo&amp;gt;. This returned value can be compared with another one using operators == and != or can serve to obtain a null-terminated character sequence representing the data type or class name by using its name() member. &lt;/p&gt;&lt;br /&gt;&lt;div align="justify"&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;// typeid&lt;br /&gt;#include &amp;lt;iostream&amp;gt;#include &amp;lt;typeinfo&amp;gt;using namespace std;&lt;br /&gt;&lt;br /&gt;int main () {&lt;br /&gt;  int * a,b;&lt;br /&gt;  a=0; b=0;&lt;br /&gt;  if (typeid(a) != typeid(b))&lt;br /&gt;  {&lt;br /&gt;    cout &amp;lt;&amp;lt; "a and b are of different types:\n";&lt;br /&gt;    cout &amp;lt;&amp;lt; "a is: " &amp;lt;&amp;lt; typeid(a).name() &amp;lt;&amp;lt; '\n';&lt;br /&gt;    cout &amp;lt;&amp;lt; "b is: " &amp;lt;&amp;lt; typeid(b).name() &amp;lt;&amp;lt; '\n';&lt;br /&gt;  }&lt;br /&gt;  return 0;&lt;br /&gt;}&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;br /&gt;&lt;p align="justify"&gt;When typeid is applied to classes typeid uses the RTTI to keep track of the type of dynamic objects. When typeid is applied to an expression whose type is a polymorphic class, the result is the type of the most derived complete object:&lt;/p&gt;&lt;br /&gt;&lt;div align="justify"&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;// typeid, polymorphic class&lt;br /&gt;#include &amp;lt;iostream&amp;gt;#include &amp;lt;typeinfo&amp;gt;#include &amp;lt;exception&amp;gt;using namespace std;&lt;br /&gt;&lt;br /&gt;class CBase { virtual void f(){} };&lt;br /&gt;class CDerived : public CBase {};&lt;br /&gt;&lt;br /&gt;int main () {&lt;br /&gt;  try {&lt;br /&gt;    CBase* a = new CBase;&lt;br /&gt;    CBase* b = new CDerived;&lt;br /&gt;    cout &amp;lt;&amp;lt; "a is: " &amp;lt;&amp;lt; typeid(a).name() &amp;lt;&amp;lt; '\n';&lt;br /&gt;    cout &amp;lt;&amp;lt; "b is: " &amp;lt;&amp;lt; typeid(b).name() &amp;lt;&amp;lt; '\n';&lt;br /&gt;    cout &amp;lt;&amp;lt; "*a is: " &amp;lt;&amp;lt; typeid(*a).name() &amp;lt;&amp;lt; '\n';&lt;br /&gt;    cout &amp;lt;&amp;lt; "*b is: " &amp;lt;&amp;lt; typeid(*b).name() &amp;lt;&amp;lt; '\n';&lt;br /&gt;  } catch (exception&amp;amp; e) { cout &amp;lt;&amp;lt; "Exception: " &amp;lt;&amp;lt; e.what() &amp;lt;&amp;lt; endl; }&lt;br /&gt;  return 0;&lt;br /&gt;}&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;br /&gt;&lt;p align="justify"&gt;Note: The string returned by member name of type_info depends on the specific implementation of your compiler and library. It is not necessarily a simple string with its typical type name, like in the compiler used to produce this output. &lt;br&gt;&lt;br&gt;Notice how the type that typeid considers for pointers is the pointer type itself (both a and b are of type class CBase *). However, when typeid is applied to objects (like *a and *b) typeid yields their dynamic type (i.e. the type of their most derived complete object).&lt;br&gt;&lt;br&gt;If the type typeid evaluates is a pointer preceded by the dereference operator (*), and this pointer has a null value, typeid throws a bad_typeid exception.&lt;br&gt;&lt;br&gt;What our compiler returned in the calls type_info::name in the this example, our compiler generated names that are easily understandable by humans, but this is not a requirement: a compiler may just return any string.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-6222893789456438084?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/6222893789456438084/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/type-casting-in-c.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/6222893789456438084'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/6222893789456438084'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/type-casting-in-c.html' title='Type Casting in C++'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-447448567282804022</id><published>2011-07-18T03:18:00.001-07:00</published><updated>2011-07-18T04:40:50.428-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Games'/><category scheme='http://www.blogger.com/atom/ns#' term='Android Games'/><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><category scheme='http://www.blogger.com/atom/ns#' term='Best Andoird Games'/><title type='text'>My Favorite Android Games</title><content type='html'>&lt;p align="justify"&gt;There are thousands of games out there in market most of them are paid or free, but which one do you like, I did refer to people’s blog to find it out, and many like variety of games. But here is the list of paid and free games which I liked, and I play almost every day.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh3.ggpht.com/-qATWC54mCpA/TiQIZ4PLZ0I/AAAAAAAAHEY/MiDD9JGlT14/s1600-h/Angry%252520Birds%252520Rio%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Angry Birds Rio" border="0" alt="Angry Birds Rio" align="left" src="http://lh6.ggpht.com/-1DWKuPYxp8Q/TiQIakrrwzI/AAAAAAAAHEc/J5d0coSlPKk/Angry%252520Birds%252520Rio_thumb%25255B1%25255D.jpg?imgmax=800" width="312" height="210"&gt;&lt;/a&gt;&lt;strong&gt;Angry Birds Rio &lt;/strong&gt;is a variant of original Angry birds, so obviously it’s a FUN game, here you have different types of levels which makes it more attractive compared to the original game. They keep updating, so more fun to come in future. It’s free game but comes with Ads, if you disable the data connection while playing this game then you won’t see any ads, that’s the best way to deal with it.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh6.ggpht.com/-rbtuvl_w4iQ/TiQIbLlBqsI/AAAAAAAAHEg/Jtz3HJUP4wc/s1600-h/Angry%252520Birds%252520Seasons%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Angry Birds Seasons" border="0" alt="Angry Birds Seasons" align="left" src="http://lh4.ggpht.com/-nGB-aAdkr9g/TiQIb_98L9I/AAAAAAAAHEk/EmWKCLWN8ac/Angry%252520Birds%252520Seasons_thumb%25255B1%25255D.jpg?imgmax=800" width="309" height="207"&gt;&lt;/a&gt;&lt;strong&gt;Angry Birds Seasons &lt;/strong&gt;is another variant where in you can play them in different seasons such as Christmas, in snow falls etc., more or less same as the original one, but here you have some bonus levels if you complete all levels in 3 stars, so kind of challenging and keeps the game spirit on till the end of the game&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh5.ggpht.com/-2tGMeRHqQFY/TiQIcXIjFeI/AAAAAAAAHEo/EygARh_dvgE/s1600-h/Angry%252520Birds%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Angry Birds" border="0" alt="Angry Birds" align="left" src="http://lh4.ggpht.com/-Sgc5o9uIfzA/TiQIdDt_q8I/AAAAAAAAHEs/sDlR-Outc1M/Angry%252520Birds_thumb%25255B1%25255D.jpg?imgmax=800" width="312" height="210"&gt;&lt;/a&gt;&lt;strong&gt;Angry Birds (Original) &lt;/strong&gt;is a fun game, and you will get addicted to this game so fast that every night you have to play this before going to sleep, that’s the level of addiction. &lt;/p&gt; &lt;p align="justify"&gt;Its whole aim is to use some physics knowledge and make the birds jump on the pigs and destroy them, who takes the eggs of these birds. There will be so many obstacles when you try to destroy them, so plan well and achieve the goal.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh5.ggpht.com/-zIPs9crP8sI/TiQId-xJ_QI/AAAAAAAAHEw/TYklLt42QvY/s1600-h/Bebbled%25255B8%25255D.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Bebbled" border="0" alt="Bebbled" align="left" src="http://lh6.ggpht.com/-eJFrVzMjYRk/TiQIeb3wasI/AAAAAAAAHE0/mwRVZFe6It0/Bebbled_thumb%25255B4%25255D.jpg?imgmax=800" width="313" height="210"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Bebbled &lt;/strong&gt;may not be interesting to that extent, but it’s a good time pass game. There is a target pointes to be made for each level, and until you make those many points you wont be allowed to go to next level. You need to touch the bubbles of the same color to make them disappear and make points out of it. More bubbles of same colors come together the more points you get. &lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-FnowFjvZU1U/TiQbeuPL7cI/AAAAAAAAHE4/aQt9NlBUiZQ/s1600-h/Bonsai%252520Blast%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Bonsai Blast" border="0" alt="Bonsai Blast" align="left" src="http://lh5.ggpht.com/-cca1DmXz1vY/TiQbfqgS4qI/AAAAAAAAHE8/w6g5XJqgAA8/Bonsai%252520Blast_thumb%25255B1%25255D.jpg?imgmax=800" width="314" height="211"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Bonsai Blast &lt;/strong&gt;is the ZUMA game which we use to play in computers, where there would be a FROG at the center and colored balls would come and you need to shoot them before reaching the end point. If you make the balls of same color count more than three, then they disappear, lot more weapons etc., are there but you need to install it to explore. It is good one, but not as good as the ZUMA, but still a time pass game.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh5.ggpht.com/-5Sc1YKFH8zU/TiQbhP_IoFI/AAAAAAAAHFA/3uu3oBfyjeA/s1600-h/Bubble%252520Blast%2525202%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Bubble Blast 2" border="0" alt="Bubble Blast 2" align="left" src="http://lh6.ggpht.com/-GkA6i-u5QE4/TiQbifXYkCI/AAAAAAAAHFE/NhB2r6f36Ok/Bubble%252520Blast%2525202_thumb%25255B1%25255D.jpg?imgmax=800" width="314" height="210"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Bubble Blast 2, &lt;/strong&gt;I have never played the first version. This one has lot of levels, may be I would never be able to complete. Its just a time pass game, you don’t need to know anything, and its very difficult to plan the game also, but over all it’s a time pass game. Keep touching the bubbles and they grow and finally blast, there are some restrictions on the number of touches you need to finish blasting all the bubbles, sometimes if becomes so difficult that you may have to take an hint. Only one hint per day.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh4.ggpht.com/-0lqmERd7KJc/TiQbk00MasI/AAAAAAAAHFI/an9nc44o2-o/s1600-h/Klondike%252520Solitaire%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top: 0px; border-right: 0px; padding-top: 0px" title="Klondike Solitaire" border="0" alt="Klondike Solitaire" align="left" src="http://lh4.ggpht.com/-DCyPIqqxaI8/TiQbmMfrFcI/AAAAAAAAHFM/ETnpewpsONE/Klondike%252520Solitaire_thumb%25255B1%25255D.jpg?imgmax=800" width="303" height="204"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Klondike Solitaire&lt;/strong&gt;&amp;nbsp; is the best solitaire game I have come across for android devices, and this one is simple and intuitive, and easy to use game. A very good time pass game. Levels are somewhat difficult.&lt;/p&gt; &lt;p align="justify"&gt;Just disable the data connections, else the ads would be irritating. &lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh3.ggpht.com/-PIhKC9ncOYk/TiQbnFC2KMI/AAAAAAAAHFQ/W9tQ1PuLcew/s1600-h/Magic%252520Marker%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top: 0px; border-right: 0px; padding-top: 0px" title="Magic Marker" border="0" alt="Magic Marker" align="left" src="http://lh3.ggpht.com/-glyStktUSY0/TiQboDry-KI/AAAAAAAAHFU/OmuEvTVWUPg/Magic%252520Marker_thumb%25255B1%25255D.jpg?imgmax=800" width="299" height="201"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Magic Marker &lt;/strong&gt;is not a game, but it’s a FUN app, with which you can make your phone a drawing board, and draw in different colors, which come as magic lights. If you want to write something and show to someone special may be this would come in handy.&lt;/p&gt; &lt;p align="justify"&gt;I have the pretty old version which does not have ads, but recent version comes with ads, so you may have some irritating ads popping up in the screen.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh5.ggpht.com/-PSkOwkoRzX0/TiQbp-XZ68I/AAAAAAAAHFY/IL1BtEg_TKg/s1600-h/Need%252520for%252520Speed%252520Shift%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top: 0px; border-right: 0px; padding-top: 0px" title="Need for Speed Shift" border="0" alt="Need for Speed Shift" align="left" src="http://lh3.ggpht.com/-4scV13kJSRU/TiQbqpuIhMI/AAAAAAAAHFc/7J-VHRC3qNQ/Need%252520for%252520Speed%252520Shift_thumb%25255B1%25255D.jpg?imgmax=800" width="315" height="212"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Need For Speed (NFS) Shift, &lt;/strong&gt;if you are a fan of NFS and or a fan of racing, then this is one game you must buy, such an awesome graphics and such a wonderful game play, you would love it. &lt;/p&gt; &lt;p align="justify"&gt;There are different tracks and different cars. You need to buy the cars from the money you make from racing and build your career.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh3.ggpht.com/-SS8iWzuIPJ8/TiQbrj_UafI/AAAAAAAAHFg/vBS8ewz6Dbo/s1600-h/Paper%252520Toss%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top: 0px; border-right: 0px; padding-top: 0px" title="Paper Toss" border="0" alt="Paper Toss" align="left" src="http://lh3.ggpht.com/-IfQBbbtyIqQ/TiQbsTXhN8I/AAAAAAAAHFk/dtE-AE8EOOM/Paper%252520Toss_thumb%25255B1%25255D.jpg?imgmax=800" width="312" height="210"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Paper Toss &lt;/strong&gt;is an game for time pass when you don’t have any work to do. It’s as simple as throwing a paper into a dust bin. &lt;/p&gt; &lt;p align="justify"&gt;There are different levels such as office, toilet, airport, basement etc., where the distance would be different and the fan would be placed in different locations.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh3.ggpht.com/-d7NFKnlro1U/TiQbtd-JbMI/AAAAAAAAHFo/Wt31tJShSOU/s1600-h/Pool%252520Master%252520Pro%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top: 0px; border-right: 0px; padding-top: 0px" title="Pool Master Pro" border="0" alt="Pool Master Pro" align="left" src="http://lh4.ggpht.com/-Wr7C1EE9TfM/TiQbuTyOHJI/AAAAAAAAHFs/ANvQm7vgDsw/Pool%252520Master%252520Pro_thumb%25255B1%25255D.jpg?imgmax=800" width="312" height="210"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Pool Master Pro &lt;/strong&gt;is the best pool game I have come across for android. It has such awesome graphics that you keep playing and get addicted to it. &lt;/p&gt; &lt;p align="justify"&gt;There is one more game which is 3D but then its not as good as this. Its free and ad free. So go for it.&lt;/p&gt; &lt;p align="justify"&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-b633KvN2NfU/TiQbvO05ptI/AAAAAAAAHFw/4ibPDHN15nQ/s1600-h/Slice%252520It%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top: 0px; border-right: 0px; padding-top: 0px" title="Slice It" border="0" alt="Slice It" align="left" src="http://lh5.ggpht.com/-mlb-wpsCASY/TiQbvyW92mI/AAAAAAAAHF0/K4MhvT2KG3M/Slice%252520It_thumb%25255B1%25255D.jpg?imgmax=800" width="310" height="209"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Slice it! &lt;/strong&gt;is a game mostly for kids, but still it’s a FUN game you can play. You will be given objects of different shape and you need to slice them into N equal parts by certain number of counts.&lt;/p&gt; &lt;p align="justify"&gt;Initially the game would be easier, and it keeps becoming complex as you go up. You may have to check your geometric skills once again. Its not as simple as slicing a piece of cake. Mind it! &lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-447448567282804022?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/447448567282804022/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/my-favorite-android-games.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/447448567282804022'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/447448567282804022'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/my-favorite-android-games.html' title='My Favorite Android Games'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://lh6.ggpht.com/-1DWKuPYxp8Q/TiQIakrrwzI/AAAAAAAAHEc/J5d0coSlPKk/s72-c/Angry%252520Birds%252520Rio_thumb%25255B1%25255D.jpg?imgmax=800' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-5036116232586949108</id><published>2011-07-18T00:41:00.001-07:00</published><updated>2011-07-19T23:30:29.728-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Smart Phone'/><category scheme='http://www.blogger.com/atom/ns#' term='Favorite Andoird Apps'/><category scheme='http://www.blogger.com/atom/ns#' term='Android Apps'/><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><title type='text'>My Android App Collection</title><content type='html'>&lt;p align="justify"&gt;These are the apps I use on my phone, and most of them are free except for few, If you too like it, just install and enjoy.&lt;/p&gt; &lt;p align="justify"&gt;Most of them are useful on daily basis, and I usually don’t keep redundant useless applications, so you can be sure of the usefulness of them, and finally it all depends on your need, so may be some of them are not needed for you. &lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh4.ggpht.com/-pb0kd8sA1OU/TiPjkknm11I/AAAAAAAAHCY/VxyYrGboGEk/s1600-h/Evernote4.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 9px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Evernote" border="0" alt="Evernote" align="left" src="http://lh5.ggpht.com/-elvqFyghUh0/TiPjll7PJMI/AAAAAAAAHCc/HlkEBst9ZIk/Evernote_thumb2.jpg?imgmax=800" width="312" height="209"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Ever note &lt;/strong&gt;is mostly useful if you have lot of things to note down in life, and you use multiple devices to update and view your note, then this is the best application for you, it stores notes on cloud, so you can access on computer and android using suitable clients.&lt;/p&gt; &lt;p align="justify"&gt;Available on android market for free, the free version has monthly 60MB storage limit, but that’s more than enough for any heavy use cases. &lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh5.ggpht.com/-jPjQ3HaiBNE/TiPjmKnxs7I/AAAAAAAAHCg/GMb28X1GqPI/s1600-h/Dropbox%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Dropbox" border="0" alt="Dropbox" align="left" src="http://lh5.ggpht.com/-e2OduGJihmo/TiPjnK9lTtI/AAAAAAAAHCk/1kqO3d566UY/Dropbox_thumb%25255B1%25255D.jpg?imgmax=800" width="312" height="209"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Drop box &lt;/strong&gt;is useful when you want to share your documents across devices, such as home computer, office, and mobile. If it’s a simple note, you can use ever note, but when it’s a document you can go ahead with drop box, it’s a free app, and you also get a windows client for your computer, with 2GB data limit, which is mostly enough, if you need more space, you can upgrade to premium user. The Microsoft SkyDrive sync storage also does the same work, but because the document cannot be accessed on mobile, this has an edge when you also want to access few documents on your phone.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh3.ggpht.com/-NNaMchLGBIQ/TiPtHwzME9I/AAAAAAAAHCo/4W_SdIPD6HA/s1600-h/SoundHound%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="SoundHound" border="0" alt="SoundHound" align="left" src="http://lh3.ggpht.com/--nHoBS0dke4/TiPtIh1ZnAI/AAAAAAAAHCs/wagSCY0uQ6c/SoundHound_thumb%25255B1%25255D.jpg?imgmax=800" width="311" height="209"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Sound Hound &lt;/strong&gt;is an application which records the audio you are listening to and then searches in the sound tag data base to find out which album and song it is, so if you are listening to some song on FM and not able to recognize which song it is this comes for help, just click sound hound and find out the song, you need wi-fi or data connection for this tagging to work. Its pretty much better than the Shaazan application, which use to crash or freeze for me in my Galaxy SL.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh4.ggpht.com/-LuLbNDufV8c/TiPtJtkqGCI/AAAAAAAAHCw/OGtnt_RhMpc/s1600-h/Saavn%252520Music%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Saavn Music" border="0" alt="Saavn Music" align="left" src="http://lh4.ggpht.com/-n8nsWFdnjhI/TiPtK0rl3LI/AAAAAAAAHC0/Uv2aTs0juUM/Saavn%252520Music_thumb%25255B1%25255D.jpg?imgmax=800" width="302" height="203"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Saavn Music &lt;/strong&gt;is for Hindi music lovers, if you have an Wi-Fi on 3G then you can listen to any of the Hindi songs, you don’t have to store them on your phone. It also has an option to choose most played songs of the week and random songs to give you surprise. It’s a free application. It can also be accessed by web on you computer, if you create a login with them you can keep track of your favorites and you can also make your own play lists.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh3.ggpht.com/-D9krYWfojjc/TiPtLZV2VnI/AAAAAAAAHC4/2X1f4Jc5uZM/s1600-h/CSipSimple%25255B3%25255D.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="CSipSimple" border="0" alt="CSipSimple" align="left" src="http://lh4.ggpht.com/-fSCLZoGPUY8/TiPtMcRfiCI/AAAAAAAAHC8/4TNBMgdpIII/CSipSimple_thumb%25255B1%25255D.jpg?imgmax=800" width="307" height="205"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;CSipSimple &lt;/strong&gt;is an open source SIP client for android, and it has lot of features which you need to explore by using it. It is an application basically for making voip calls directly from your phone without using a computer or laptop. I have configured my nymgo account with this so I can make nymgo calls from here, It works pretty well on the GPRS/EDGE connection as well. If it does not work for you check your provides audio codec settings and you can easily fix it to work.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh4.ggpht.com/-PiXO2tKAbxA/TiP-xedz2BI/AAAAAAAAHDU/w8hPEalWooU/s1600-h/Free-SMS-Sender3.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Free SMS Sender" border="0" alt="Free SMS Sender" align="left" src="http://lh3.ggpht.com/-AgBpJOQ3G5E/TiQAbkyE-tI/AAAAAAAAHDc/tmZxhzZfhPk/Free-SMS-Sender_thumb1.jpg?imgmax=800" width="314" height="211"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Free SMS Sender &lt;/strong&gt;is an awesome application I found recently, its based on free SMS gateways such as way2sms.com etc. The main advantage of this application is that it is very similar GUI as that of the native application, and may be little better, it also updates the same data base of SMS which native application does, so they are inter operable, and hence you have lot of flexibility. You just need to configure your gateway for sms and you are done, keep sending SMS for free. Best part is this application is free and ad free. &lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-RMYuPuBvirY/TiQAcl6PALI/AAAAAAAAHDg/iwxrjoWc7zU/s1600-h/IM-Pro3.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="IM  Pro" border="0" alt="IM  Pro" align="left" src="http://lh3.ggpht.com/-t6i2o5V083Y/TiQAdVqFwiI/AAAAAAAAHDk/vHxi9lbsT28/IM-Pro_thumb1.jpg?imgmax=800" width="316" height="213"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;IM+ Pro &lt;/strong&gt;is really an awesome IM application, which supports most of the messaging protocols including Jabber, You can use it as Yahoo messenger, facebook chat, google talk, and lot more. The reason I bought this is I wanted to use it for my official messenger, which is a jabber based, it works very good with IM+ and the free version has ads to its kind of irritating, and so this is the perfect companion. I also use it with FB, because it way better than the chat provided by the FB official application.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-PT2tU4S0mRk/TiQAd9AqkuI/AAAAAAAAHDo/zzZUOXObkgE/s1600-h/Cisco-Webex-Meetings3.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Cisco Webex Meetings" border="0" alt="Cisco Webex Meetings" align="left" src="http://lh6.ggpht.com/-0PSn7KiQBKE/TiQAemgLjRI/AAAAAAAAHDs/JiHnCnpFe70/Cisco-Webex-Meetings_thumb1.jpg?imgmax=800" width="314" height="210"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Cisco WebEx Meetings &lt;/strong&gt;is an android client for attending WebEx meetings, its such an awesome thing that you can attend meetings and watch presentations wherever you are right on your phone. You can watch the scheduled meetings, create new ones and chat with the attendees, and best part is you can get a call back on your phone, you don’t need to open your laptop just for attending some meeting. That rocks!, if you are a cisco employee, you need get a separate password for your account from GTRC support, as the original password does not work for security reasons.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh4.ggpht.com/-8MN2_s3eNA8/TiQAfV2usaI/AAAAAAAAHDw/dBlCaE1J2_E/s1600-h/Barcode-Scanner3.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Barcode Scanner" border="0" alt="Barcode Scanner" align="left" src="http://lh3.ggpht.com/-1wlvXTOjJt8/TiQAf24fwfI/AAAAAAAAHD0/VuQDjvlJ-SQ/Barcode-Scanner_thumb1.jpg?imgmax=800" width="304" height="204"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Barcode Scanner &lt;/strong&gt;is mostly not useful in India as it does not recognize any of the barcodes on products to give details about product, it just reads and gives some number. It would be useful when used to scan OR codes for links which are either printed on paper or on some websites. And may be if you frequently travel outside if might come handy, I am not very sure. But its kind of must have application, you may need it sometime.&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Social Apps&lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh5.ggpht.com/-E99pO9A0I4Y/TiQAgaRvgaI/AAAAAAAAHD4/M8ilBXHzvyk/s1600-h/Facebook-for-Android3.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Facebook for Android" border="0" alt="Facebook for Android" align="left" src="http://lh5.ggpht.com/-bsphwsIAjbM/TiQAhFNQitI/AAAAAAAAHD8/5UEXDMDLXwQ/Facebook-for-Android_thumb1.jpg?imgmax=800" width="315" height="211"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Facebook for Android, &lt;/strong&gt;If you love social networking, then may be you are on FB, then you can download this application. It’s the official Facebook application on android. Its pretty cool, but some things you cannot do on this application, you may have to open the web page to do it. But overall it is enough for your social activities on FB. For FB chat use the IM+ mentioned above, that’s much better.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh5.ggpht.com/-mcWdgXgU3Yk/TiQAhvmCF_I/AAAAAAAAHEA/ClrYFapCeVA/s1600-h/Twitter3.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Twitter" border="0" alt="Twitter" align="left" src="http://lh6.ggpht.com/-xUvnMLcB4No/TiQAiShQhqI/AAAAAAAAHEE/QznU3a57oHo/Twitter_thumb1.jpg?imgmax=800" width="316" height="212"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Twitter, &lt;/strong&gt;I don’t use this application or the twitter much, but may be some day I would use it ! So I keep it for a while, until I decide myself that its of no use. &lt;/p&gt; &lt;p align="justify"&gt;But to be honest, lot of people like to twit and for them this is the official application, its pretty good and stable. so go ahead and use it. &lt;/p&gt; &lt;p&gt;&lt;a href="http://lh4.ggpht.com/-w9raEY370Cc/TiQAi5DMewI/AAAAAAAAHEI/jWupdH9I4y8/s1600-h/Google3.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Google " border="0" alt="Google " align="left" src="http://lh5.ggpht.com/-UAjVVX7PwRE/TiQAjp1CPtI/AAAAAAAAHEM/7wIwd9IoOzc/Google_thumb1.jpg?imgmax=800" width="313" height="210"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Google+ &lt;/strong&gt;is the social networking application from Google for their Google+ website. This is pretty much new, but looks good and promising. There are few issues with this application as of now, like you don’t get notifications until you open the app. In a way its good, but it’s a bug. It also comes with another sub app called Huddle, with which you can do group chat over Google talk, and that’s pretty cool though I have never used it.&lt;/p&gt; &lt;p align="justify"&gt;&lt;a href="http://lh4.ggpht.com/-6CFngQscl1c/TiQAkC3PwEI/AAAAAAAAHEQ/akJYuSfHWx0/s1600-h/Google-Docs3.jpg"&gt;&lt;img style="background-image: none; border-right-width: 0px; margin: 0px 10px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Google Docs" border="0" alt="Google Docs" align="left" src="http://lh5.ggpht.com/-SKunPbZf0O8/TiQAkmQ-v2I/AAAAAAAAHEU/p3QncSF55Tc/Google-Docs_thumb1.jpg?imgmax=800" width="313" height="210"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Google Docs &lt;/strong&gt;is the client for Google docs on android, and possibly Google realized lately that we should also have an application for docs, so as to provide access to the docs from phone in a much better way. &lt;/p&gt; &lt;p align="justify"&gt;In fact this is pretty good, and it has it’s own PDF viewer. Its still in early stages, but works well for me. I was waiting for this app from the day I bought my phone. Go for it.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-5036116232586949108?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/5036116232586949108/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/my-android-app-collection.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5036116232586949108'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5036116232586949108'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/my-android-app-collection.html' title='My Android App Collection'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://lh5.ggpht.com/-elvqFyghUh0/TiPjll7PJMI/AAAAAAAAHCc/HlkEBst9ZIk/s72-c/Evernote_thumb2.jpg?imgmax=800' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-3968960700384889252</id><published>2011-07-17T09:10:00.001-07:00</published><updated>2011-07-17T09:10:30.387-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Gladinet'/><category scheme='http://www.blogger.com/atom/ns#' term='Storage'/><category scheme='http://www.blogger.com/atom/ns#' term='cloud'/><category scheme='http://www.blogger.com/atom/ns#' term='Windows'/><category scheme='http://www.blogger.com/atom/ns#' term='Skydrive'/><title type='text'>Windows SkyDrive and Sync Storage</title><content type='html'>&lt;p align="justify"&gt;Now Microsoft has introduced an upgraded version of &lt;a href="http://skydrive.live.com/"&gt;Live SkyDrive&lt;/a&gt;, a free online file storage service, that looks like a perfect choice at the moment for several reasons. &lt;ul&gt; &lt;li&gt; &lt;div align="justify"&gt;You get 25 GB of free online storage space for your documents, photos, and all other files - the previous limit was &lt;a href="http://www.labnol.org/internet/tools/microsoft-windows-live-skydrive-5-gb-storage-space/2348/"&gt;5 GB&lt;/a&gt;. Now you have 5GB sync storage and you can use it as a replacement to Dropbox and keep all your file in sync across your computers using Live Mesh.&lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;You have the option to download an entire folder on SkyDrive as a local zip file - huge time saver.&lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;You can upload files to SkyDrive through Windows Explorer itself through &lt;a href="http://www.gladinet.com/p/index.htm"&gt;Gladinet&lt;/a&gt; - it's just like mapping a folder on the network drive.&lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;SkyDrive is like a social network for files. You can see files that your friends have shared on SkyDrive through your own Live Profile page (similar to Friend updates in Facebook).&lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;SkyDrive is Microsoft service and an integral part of their larger Windows Live strategy so you really don't have to worry about its future existence.&lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;Microsoft will soon offer an Online Office suite (like Google Docs) and it's a no brainer that documents uploaded to SkyDrive will be accessible from Online Office and vice-versa. Thus you indirectly get more storage space for documents.&lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;SkyDrive has no real competition. Google and Yahoo do not have a presence in the online file storage market while services like DropBox, Mozy, Box.net, etc. offer only limited space (couple of gigs.) to free users.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt; &lt;p align="justify"&gt;So, over all it’s the best cloud storage as of now, as good as Google Docs, Microsoft is trying his best to come back again in the battle on the clouds.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-3968960700384889252?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/3968960700384889252/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/windows-skydrive-and-sync-storage.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3968960700384889252'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3968960700384889252'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/windows-skydrive-and-sync-storage.html' title='Windows SkyDrive and Sync Storage'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-1579065280474035073</id><published>2011-07-17T09:01:00.001-07:00</published><updated>2011-07-17T09:01:08.886-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Windows'/><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><title type='text'>Setup Hot mail on your Android device</title><content type='html'>&lt;p&gt;&lt;em&gt;This solution article provided information on how to setup your Hotmail account on Android phones.&lt;br&gt;&lt;/em&gt;&lt;br&gt;Account settings and their level of support will vary across Android phones. While the steps to configure push email with synced contacts and calendar will vary, we have found these steps to work across a number of phones:&lt;/p&gt; &lt;ol&gt; &lt;li&gt;Select “Email” client on phone. &lt;li&gt;Press menu and select “Add account” &lt;li&gt;Enter full Hotmail address: e.g. &lt;a href="mailto:username@hotmail.com"&gt;username@hotmail.com&lt;/a&gt; or &lt;a href="mailto:username@live.com"&gt;username@live.com&lt;/a&gt; &lt;li&gt;Enter password &lt;li&gt;Select “Manual setup” &lt;li&gt;Select “Exchange” when prompted for “What type of account is this?” &lt;li&gt;Domain/Username, enter full Hotmail address: e.g. &lt;a href="mailto:username@hotmail.com"&gt;username@hotmail.com&lt;/a&gt;. (Note: if the device only says “Domain”, it should be left blank. If the device says “Username”, then enter the full Hotmail address. On some devices, the Domain/Username may be pre-populated incorrectly and should be erased. &lt;li&gt;Type in password. (may already be filled in) &lt;li&gt;Server name. Enter: &lt;a href="http://m.hotmail.com/"&gt;m.hotmail.com&lt;/a&gt; for server name. (Note: this field may be pre-populated incorrectly depending on device). &lt;li&gt;Make sure box “Use secure connection (SSL)” is checked. &lt;li&gt;Select “Next” &lt;li&gt;Select desired account options for inbox checking frequency, number of days to synchronize, send email by default, notifications and contacts/calendar sync. Select “Next” &lt;li&gt;Depending on device you may be prompted for account color and account name (e.g. “Hotmail”) &lt;li&gt;Select “Next” and your Hotmail is set-up and ready to go!&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;If these steps aren’t working, you can always access Hotmail through your phones browser at &lt;a href="http://www.hotmail.com/"&gt;www.hotmail.com&lt;/a&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-1579065280474035073?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/1579065280474035073/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/setup-hot-mail-on-your-android-device.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1579065280474035073'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1579065280474035073'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/setup-hot-mail-on-your-android-device.html' title='Setup Hot mail on your Android device'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-6361932433529426258</id><published>2011-07-17T08:57:00.001-07:00</published><updated>2011-07-17T08:57:39.536-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Google Interview Questions'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><title type='text'>Google and Family Planning!– Interesting answer</title><content type='html'>&lt;p align="justify"&gt;The following question is reputedly one of many that Google may ask prospective job candidates:&lt;br&gt;&lt;br&gt;Imagine a country in which every family continues to have children until they have a boy. If they have a girl, they have another child, and continue until they have a boy, then they stop. What is the proportion of boys to girls in the country? You should assume that there is an equal probability of having a boy or a girl.&lt;br&gt;&lt;br&gt;The question has been discussed at length on the Internet and &lt;a href="http://www.businessinsider.com/answers-to-15-google-interview-questions-that-will-make-you-feel-stupid-2009-11#in-a-country-in-which-people-only-want-boys-3"&gt;this site&lt;/a&gt; is one of many that provide an answer. The answer is correct (approximately the same number of boys and girls) but I doubt whether the way it is derived would help to get you a job with Google. There are numerous other similar posts, most of which give the correct answer, but all but a few miss what I believe is the point of the question. It is an example of misdirection; the question describes a strategy for ensuring that all families have exactly one boy and zero or more girls, but what it asks for is the overall distribution of boys and girls in the country as a whole. The way the question is stated leads you to believe that the strategy will affect the overall distribution - but does it? Anyone with some knowledge of probability should then realise that no strategy that involves stopping after a certain number of children can affect the overall proportion, because all births are independent events. In the population as a whole the probability that the next child, born anywhere in the country, will be a boy is 0.5, regardless of how many boys or girls have already been born, so the proportion will be 50:50. Of course the proportion will rarely be exactly equal because the gender of the children are random events, in fact they form a &lt;a href="http://en.wikipedia.org/wiki/Binomial_distribution"&gt;binomial distribution&lt;/a&gt;, but for large populations it will be very close to 50:50.&lt;br&gt;&lt;br&gt;To many people this is counter intuitive - probably because the strategy clearly does affect the make up of every individual family. Consider another country where they adopt the strategy of stopping after having exactly two girls. The only family distribution you would find on both countries would be two girls and one boy (but in a different order); the overall distribution however would still be 50:50.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-6361932433529426258?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/6361932433529426258/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/google-and-family-planning-interesting.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/6361932433529426258'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/6361932433529426258'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/07/google-and-family-planning-interesting.html' title='Google and Family Planning!– Interesting answer'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-2303834497689919623</id><published>2011-06-28T07:12:00.001-07:00</published><updated>2011-06-28T07:12:53.694-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='stack direction'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><category scheme='http://www.blogger.com/atom/ns#' term='stack'/><title type='text'>Finding Stack Direction for a Machine</title><content type='html'>&lt;p&gt;How would you find out if a machine’s stack grows up or down in memory?&lt;/p&gt; &lt;p&gt;You need to call a function with one parameter, and create one more local variable, the parameters would be pushed on stack and also the local variables would be created on stack, hence, if your parameters address and locals address would give you the result.&lt;/p&gt; &lt;p&gt;Here is the code of subroutine for your reference.&lt;/p&gt;&lt;pre style="border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; padding-bottom: 5px; line-height: 14px; background-color: #eee; padding-left: 5px; width: 100%; padding-right: 5px; font-family: andale mono, lucida console, monaco, fixed, monospace; color: #000000; font-size: 12px; overflow: auto; border-top: #999999 1px dashed; border-right: #999999 1px dashed; padding-top: 5px"&gt;&lt;code&gt;void sub_routine(int a) { &lt;br /&gt;    int b;&lt;br /&gt;    b = a;&lt;br /&gt;    if(&amp;amp;b &amp;lt; &amp;amp;a) &lt;br /&gt;        printf("Stack Grows Downward!");&lt;br /&gt;    else&lt;br /&gt;        printf("Stack Grows Upward!");&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;int main() {&lt;br /&gt;    sub_routine(10);&lt;br /&gt;    return 0;&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-2303834497689919623?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/2303834497689919623/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/finding-stack-direction-for-machine.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2303834497689919623'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2303834497689919623'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/finding-stack-direction-for-machine.html' title='Finding Stack Direction for a Machine'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-6326737790914550199</id><published>2011-06-28T02:56:00.001-07:00</published><updated>2011-06-28T02:56:11.941-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='Logical Thinking'/><category scheme='http://www.blogger.com/atom/ns#' term='Richard Feyman'/><category scheme='http://www.blogger.com/atom/ns#' term='Microsoft Interview'/><title type='text'>If Richard Feynman applied for a job at Microsoft</title><content type='html'>&lt;p&gt;&lt;b&gt;Interviewer: &lt;/b&gt;Now comes the part of the interview where we ask a question to test your creative thinking ability. Don't think too hard about it, just apply everyday common sense, and describe your reasoning process.&lt;/p&gt; &lt;p&gt;Here's the question: Why are manhole covers round?&lt;/p&gt; &lt;p&gt;&lt;b&gt;Feynman: &lt;/b&gt;They're not. Some manhole covers are square. It's true that there are SOME round ones, but I've seen square ones, and rectangular ones.&lt;/p&gt; &lt;p&gt;&lt;b&gt;Interviewer: &lt;/b&gt;But just considering the round ones, why are they round?&lt;/p&gt; &lt;p&gt;&lt;b&gt;Feynman: &lt;/b&gt;If we are just considering the round ones, then they are round by definition. That statement is a tautology.&lt;/p&gt; &lt;p&gt;&lt;b&gt;Interviewer: &lt;/b&gt;I mean, why are there round ones at all? Is there some particular value to having round ones?&lt;/p&gt; &lt;p&gt;&lt;b&gt;Feynman: &lt;/b&gt;Yes. Round covers are used when the hole they are covering up is also round. It's simplest to cover a round hole with a round cover.&lt;/p&gt; &lt;p&gt;&lt;b&gt;Interviewer: &lt;/b&gt;Can you think of a property of round covers that gives them an advantage over square ones?&lt;/p&gt; &lt;p&gt;&lt;b&gt;Feynman: &lt;/b&gt;We have to look at what is under the cover to answer that question. The hole below the cover is round because a cylinder is the strongest shape against the compression of the earth around it. Also, the term "manhole" implies a passage big enough for a man, and a human being climbing down a ladder is roughly circular in cross-section. So a cylindrical pipe is the natural shape for manholes. The covers are simply the shape needed to cover up a cylinder.&lt;/p&gt; &lt;p&gt;&lt;b&gt;Interviewer: &lt;/b&gt;Do you believe there is a safety issue? I mean, couldn't square covers fall into the hole and hurt someone?&lt;/p&gt; &lt;p&gt;&lt;b&gt;Feynman: &lt;/b&gt;Not likely. Square covers are sometimes used on prefabricated vaults where the access passage is also square. The cover is larger than the passage, and sits on a ledge that supports it along the entire perimeter. The covers are usually made of solid metal and are very heavy. Let's assume a two-foot square opening and a ledge width of 1-1/2 inches. In order to get it to fall in, you would have to lift one side of the cover, then rotate it 30 degrees so that the cover would clear the ledge, and then tilt the cover up nearly 45 degrees from horizontal before the center of gravity would shift enough for it to fall in. Yes, it's possible, but very unlikely. The people authorized to open manhole covers could easily be trained to do it safely. Applying common engineering sense, the shape of a manhole cover is entirely determined by the shape of the opening it is intended to cover.&lt;/p&gt; &lt;p&gt;&lt;b&gt;Interviewer (troubled): &lt;/b&gt;Excuse me a moment; I have to discuss something with my management team. &lt;i&gt;(Leaves room.) &lt;/i&gt;&lt;/p&gt; &lt;p&gt;&lt;i&gt;(Interviewer returns after 10 minutes) &lt;/i&gt;&lt;/p&gt; &lt;p&gt;&lt;b&gt;Interviewer: &lt;/b&gt;We are going to recommend you for immediate hiring into the marketing department&lt;/p&gt; &lt;p&gt;&lt;em&gt;&lt;strong&gt;Source: &lt;/strong&gt;&lt;a href="http://www.sellsbrothers.com/interview?content=question.htm"&gt;http://www.sellsbrothers.com/interview?content=question.htm&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-6326737790914550199?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/6326737790914550199/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/if-richard-feynman-applied-for-job-at.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/6326737790914550199'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/6326737790914550199'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/if-richard-feynman-applied-for-job-at.html' title='If Richard Feynman applied for a job at Microsoft'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-5719211897223286805</id><published>2011-06-28T02:23:00.001-07:00</published><updated>2011-06-28T02:23:34.778-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Illegal Questions'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><title type='text'>Some ILLEGAL Questions !</title><content type='html'>&lt;ul&gt; &lt;li&gt;What political party are you affiliated with?&lt;/li&gt; &lt;li&gt;Are you a member of the local country club?&lt;/li&gt; &lt;li&gt;Do you go to church regularly?&lt;/li&gt; &lt;li&gt;Are you currently married? Are you divorced? What is your sexual orientation? &lt;/li&gt; &lt;li&gt;What are your outstanding debts?&lt;/li&gt; &lt;li&gt;What charities are you involved with?&lt;/li&gt; &lt;li&gt;Do you drink?&lt;/li&gt; &lt;li&gt;Do you have a boyfriend?&lt;/li&gt; &lt;li&gt;Your last name is _______. What kind of name is that? &lt;/li&gt; &lt;li&gt;Do you have a girlfriend / boyfriend / Are you planning to have children&lt;/li&gt; &lt;li&gt;Do you have a physical disability?&lt;/li&gt; &lt;li&gt;Do you have any health problems?&lt;/li&gt; &lt;li&gt;Have you ever been convicted of a felony?&lt;/li&gt; &lt;li&gt;How many children do you have?&lt;/li&gt; &lt;li&gt;How old are you?&lt;/li&gt; &lt;li&gt;This is a Christian company. Do you think that you can be happy working here?&lt;/li&gt; &lt;li&gt;What does you father/mother do for a living?&lt;/li&gt; &lt;li&gt;What is your first language?&lt;/li&gt; &lt;li&gt;What is your IQ?&lt;/li&gt; &lt;li&gt;How much do you weigh?&lt;/li&gt; &lt;li&gt;What's your religion?&lt;/li&gt;&lt;/ul&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-5719211897223286805?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/5719211897223286805/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/some-illegal-questions.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5719211897223286805'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5719211897223286805'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/some-illegal-questions.html' title='Some ILLEGAL Questions !'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-5651391371767885196</id><published>2011-06-28T01:45:00.001-07:00</published><updated>2011-06-28T01:45:28.073-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Google Interview Questions'/><category scheme='http://www.blogger.com/atom/ns#' term='puzzle'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='Logical Thinking'/><title type='text'>Few Google Puzzles</title><content type='html'>&lt;p align="justify"&gt;&lt;strong&gt;How do you get a fair result with an unfair coin? i.e it is expected to come more heads than tails.&lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;em&gt;&lt;strong&gt;Answer:&lt;/strong&gt;&lt;/em&gt; Take HT as Heads, and TH as Tails, and Other times re flip the coin, now the probabilities are same.&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;You have five pirates, ranked from 5 to 1 in descending order. The top pirate has the right to propose how 100 gold coins should be divided among them. But the others get to vote on his plan, and if fewer than half agree with him, he gets killed. How should he allocate the gold in order to maximize his share but live to enjoy it? (Hint: One pirate ends up with 98 percent of the gold.)&lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;&lt;em&gt;Additional Note: &lt;/em&gt;&lt;/strong&gt;&lt;/p&gt; &lt;ul&gt; &lt;li&gt; &lt;div align="justify"&gt;There are 5 rational pirates, A, B, C, D and E. They find 100 gold coins. They must decide how to distribute them. &lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;The pirates have a strict order of seniority: A is superior to B, who is superior to C, who is superior to D, who is superior to E.&lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;The pirate world's rules of distribution are thus: that the most senior pirate should propose a distribution of coins. The pirates, including the proposer, then vote on whether to accept this distribution. If the proposed allocation is approved by a majority or a tie vote, it happens. If not, the proposer is thrown overboard from the pirate ship and dies, and the next most senior pirate makes a new proposal to begin the system again.&lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;Pirates base their decisions on three factors. First of all, each pirate wants to survive. Second, each pirate wants to maximize the number of gold coins he receives. Third, each pirate would prefer to throw another overboard, if all other results would otherwise be equal&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt; &lt;p align="justify"&gt;&lt;strong&gt;&lt;em&gt;Answer:&lt;/em&gt;&lt;/strong&gt; It might be expected intuitively that Pirate A will have to allocate little if any to himself for fear of being voted off so that there are fewer pirates to share between. However, this is as far from the theoretical result as is possible. &lt;/p&gt; &lt;p align="justify"&gt;This is apparent if we work backwards: if all except D and E have been thrown overboard, D proposes 100 for himself and 0 for E. He has the casting vote, and so this is the allocation. &lt;/p&gt; &lt;p align="justify"&gt;If there are three left (C, D and E) C knows that D will offer E 0 in the next round; therefore, C has to offer E 1 coin in this round to make E vote with him, and get his allocation through. Therefore, when only three are left the allocation is C:99, D:0, E:1.&lt;/p&gt; &lt;p align="justify"&gt;If B, C, D and E remain, B knows this when he makes his decision. To avoid being thrown overboard, he can simply offer 1 to D. Because he has the casting vote, the support only by D is sufficient. Thus he proposes B:99, C:0, D:1, E:0. One might consider proposing B:99, C:0, D:0, E:1, as E knows he won't get more, if any, if he throws B overboard. But, as each pirate is eager to throw each other overboard, E would prefer to kill B, to get the same amount of gold from C.&lt;/p&gt; &lt;p align="justify"&gt;Assuming A knows all these things, he can count on C and E's support for the following allocation, which is the final solution:&lt;br&gt;A: 98 coins&lt;br&gt;B: 0 coins&lt;br&gt;C: 1 coin&lt;br&gt;D: 0 coins&lt;br&gt;E: 1 coin&lt;/p&gt; &lt;p align="justify"&gt;Also, A:98, B:0, C:0, D:1, E:1 or other variants are not good enough, as D would rather throw A overboard to get the same amount of gold from B. &lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;&lt;em&gt;Note: &lt;/em&gt;&lt;/strong&gt;The game can easily be extended to up to 200 pirates (or further even if you don't increase the amount of gold). &lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;You have to get from point A to point B. You don’t know if you can get there. What would you do?&lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;&lt;em&gt;Best Answer:&lt;/em&gt;&lt;/strong&gt; Well, point A is where you are now. You know how you go into a mall, and they have the "mall map" inside a case and you look for the "you are here" spot? That's your reference point, and if you have even the slightest sense of direction, you can find the store you want on the map and start walking to it.&lt;/p&gt; &lt;p align="justify"&gt;Next...point B. In the same scenario above point B would be the store you looked for and started walking toward. So, in other words, point B is where you want to go. In the mall example you could locate the store and go in the exact opposite direction following only the outer walls and still get there. Not very effective, but the end result would be successful...albeit very delayed.&lt;/p&gt; &lt;p align="justify"&gt;Or, you could locate the store, point yourself in that direction, and walk straight to it and get there much faster and much more efficiently. Successful end result and with a lot of extra time to spare when compared to the walking the other way. Right?&lt;/p&gt; &lt;p align="justify"&gt;Something else that can come up even in your "direct" walk to point B is distraction. After all; you're in a mall. You're bound to see some shoes you just "got to have". Or you'll stop and drool over that awesome surround sound digital megaDef home theater system. Maybe you'll decide to stop and sample that divine cinnamon roll that's been wafting up your nose for the past 15 minutes. You get the idea. Distractions can keep you from arriving at your desired location. If not for good, at least for a significantly postponed time.&lt;/p&gt; &lt;p align="justify"&gt;In your ongoing marketing efforts you need to get from point A (where you are now) to point B (your desired end result, location, or outcome) in an efficient, timely manner to be as effective and successful as possible. So you'll need to keep some key points in mind:&lt;/p&gt; &lt;ul&gt; &lt;li&gt; &lt;div align="justify"&gt;Know (not think you know) where you are&lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;Know (not think you know) where you want to go&lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;See clearly where "point B" is or clearly, vividly visualize yourself there&lt;/div&gt;&lt;/li&gt; &lt;li&gt; &lt;div align="justify"&gt;Be aware of what your distractions are or could be and build up barriers against them&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt; &lt;p align="justify"&gt;And don't stop until you get there...then you'll begin to prepare for a new "point B"&lt;br&gt;This isn't mystical. It isn't magical. It isn't mind control or mind over matter. It's the good ol' work ethic. You keep working at it until you achieve it. I don't buy into the "work smarter not harder" cliche' either. No way. You work smarter AND harder.&lt;/p&gt; &lt;p align="justify"&gt;Increase your skills consistently so you can achieve more in less time. Learn more software programs to streamline your efficiency. But then you gotta (as we used to say in high school choir) practice, practice, practice! You don't get better simply by "being smarter". I like to say: Education without Application leads to a Continuation of Frustration. So apply that wonderful brain of yours to the task at hand and do it until you do it better than anybody.&lt;/p&gt; &lt;p align="justify"&gt;Once you've developed this approach to your efforts...your sphere of influence will be made up of bold, straight lines you can walk with confidence.&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Imagine you have a closet full of shirts. It’s very hard to find a shirt. So what can you do to organize your shirts for easy retrieval?&lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;I would argue that the COLOR of the shirt is less important than the OCCASION you wear the shirt for.The best top level hash to make on the shirts would be when the shirt is appropriate to wear. Divide the shirts into Work Shirts, Leisure Shirts, and Gym Shirts (insert other categories as you see fit). Then when it’s time to select a shirt for work in the morning, you don’t have to think about what COLOR you want to wear. Maybe then organize the work shirts by color.&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;Every man in a village of 100 married couples has cheated on his wife. Every wife in the village instantly knows when a man other than her husband has cheated, but does not know when her own husband has. The village has a law that does not allow for adultery. Any wife who can prove that her husband is unfaithful must kill him that very day. The women of the village would never disobey this law. One day, the queen of the village visits and announces that at least one husband has been unfaithful. What happens?&lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;&lt;em&gt;Day1:&lt;/em&gt;&lt;/strong&gt; nothing happens. As every woman would be expecting that one of the men, she knows for adultery should die. No one would kill her own husband.&lt;br&gt;&lt;strong&gt;&lt;em&gt;Day2:&lt;/em&gt;&lt;/strong&gt; When no one dies, each woman would instantly come to know that her husband has cheated, and each woman would kill their husband. So everyone dies.&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;If the probability of observing a car in 30 minutes on a highway is 0.95, what is the probability of observing a car in 10 minutes (assuming constant default probability)? &lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;Let p be the probability of seeing a car in a given 10 minutes. Then (1-p) is the probability of not seeing a car in 10 minutes, and (1-p)3 is the probability of not seeing a car in 30 minutes. But: &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (1-p)3 = 0.05 &lt;br&gt;--&amp;gt; p = 0.63159...&lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;If you look at a clock and the time is 3:15, what is the angle between the hour and the minute hands? &lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;Assume for now the angle is 0 degrees, but hour hand moves about 0.5 degrees in one min, and in 15 minutes he moves by 7.5 degrees, so the angle is 7.5 degrees.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-5651391371767885196?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/5651391371767885196/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/few-google-puzzles.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5651391371767885196'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5651391371767885196'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/few-google-puzzles.html' title='Few Google Puzzles'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-8855434576106490234</id><published>2011-06-27T09:57:00.001-07:00</published><updated>2011-06-27T09:59:23.462-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Google Interview Questions'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='Logical Thinking'/><title type='text'>Google Interview Questions that makes you feel stupid</title><content type='html'>&lt;p align="justify"&gt;&lt;strong&gt;Why are manhole-covers round in shape?&lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;The question of why manhole covers are typically round, at least in the U.S., was made famous by Microsoft when they began asking it as a job-interview question. Originally meant as a psychological assessment of how one approaches a question with more than one correct answer, the problem has produced a number of alternate explanations  &lt;p align="justify"&gt;Reasons for the shape include:&lt;/p&gt; &lt;ul&gt; &lt;li&gt; &lt;div align="justify"&gt;A round manhole cover cannot fall through its circular opening, whereas a square manhole cover may fall in if it were inserted diagonally in the hole. (A Reuleaux triangle or other curve of constant width would also serve this purpose, but round covers are much easier to manufacture. The existence of a "lip" holding up the lid means that the underlying hole is smaller than the cover, so that other shapes might suffice.)&lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;Round tubes are the strongest and most material-efficient shape against the compression of the earth around them, and so it is natural that the cover of a round tube assumes a circular shape.&lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;Similarly, it is easier to dig a circular hole and thus the cover is also circular.&lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;The bearing surfaces of manhole frames and covers are machined to assure flatness and prevent them from becoming dislodged by traffic. Round castings are much easier to machine using a lathe.&lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;Circular covers do not need to be rotated to align them when covering a circular manhole.&lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;Human beings have a roughly circular cross-section.&lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;A round manhole cover can be more easily moved by being rolled.&lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;A round manhole cover is cheapest to manufacture related to other shapes because requires the least amount of metal to cover an opening wide enough for a person to get through.&lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;Most manhole covers are made by a few large companies. A different shape would have to be custom made.&lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;The round manhole cover can more easily accommodate a Ninja Turtles shell&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt; &lt;p align="justify"&gt;&lt;strong&gt;How many golf balls can fit in a school bus?&lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;This is one of those questions Google asks just to see if the applicant can explain the key challenge to solving the problem.  &lt;p align="justify"&gt;I figure a standard school bus is about 8ft wide by 6ft high by 20 feet long - this is just a guess based on the thousands of hours I have been trapped behind school buses while traffic in all directions is stopped.  &lt;p align="justify"&gt;That means 960 cubic feet and since there are 1728 cubic inches in a cubit foot, that means about 1.6 million cubic inches.&amp;nbsp; &lt;p align="justify"&gt;I calculate the volume of a golf ball to be about 2.5 cubic inches (4/3 * pi * .85) as .85 inches is the radius of a golf ball.&amp;nbsp; &lt;p align="justify"&gt;Divide that 2.5 cubic inches into 1.6 million and you come up with 660,000 golf balls. However, since there are seats and crap in there taking up space and also since the spherical shape of a golf ball means there will be considerable empty space between them when stacked, I'll round down to 500,000 golf balls.&amp;nbsp; &lt;p align="justify"&gt;Which sounds ludicrous. I would have spitballed no more than 100k. But I stand by my math.&amp;nbsp; &lt;p align="justify"&gt;&lt;strong&gt;How much should you charge to wash all the windows in Seattle?&lt;/strong&gt;  &lt;p align="justify"&gt;This is one of those questions where the trick is to come up with an easier answer than the one that's seemingly being called for. We'd say. "$10 per window."  &lt;p align="justify"&gt;&lt;strong&gt;In a country in which people only want boys every family continues to have children until they have a boy. If they have a girl, they have another child. If they have a boy, they stop. What is the proportion of boys to girls in the country?&lt;/strong&gt;  &lt;p align="justify"&gt;This one caused quite the debate, but we figured it out following these steps:  &lt;ul&gt; &lt;li&gt; &lt;div align="justify"&gt;Imagine you have 10 couples who have 10 babies. 5 will be girls. 5 will be boys. (Total babies made: 10, with 5 boys and 5 girls) &lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;The 5 couples who had girls will have 5 babies. Half (2.5) will be girls. Half (2.5) will be boys. Add 2.5 boys to the 5 already born and 2.5 girls to the 5 already born. (Total babies made: 15, with 7.5 boys and 7.5 girls.) &lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;The 2.5 couples that had girls will have 2.5 babies. Half (1.25) will be boys and half (1.25) will be girls. Add 1.25 boys to the 7.5 boys already born and 1.25 girls to the 7.5 already born. (Total babies: 17.5 with 8.75 boys and 8.75 girls).&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt; &lt;p align="justify"&gt;And so on, maintianing a 50/50 population. &lt;/p&gt; &lt;p align="justify"&gt;&lt;strong&gt;How many piano tuners are there in the entire world?&lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;We'd answer "However many the market dictates. If pianos need tuning once a week, and it takes an hour to tune a piano and a piano tuner works 8 hours a day for 5 days a week 40 pianos need tuning each week. We'd answer one for every 40 pianos."&lt;/p&gt; &lt;p align="justify"&gt;On Wikipedia, they call this a Fermi problem.&lt;/p&gt; &lt;p align="justify"&gt;The classic Fermi problem, generally attributed to Fermi, is "How many piano tuners are there in Chicago?" A typical solution to this problem would involve multiplying together a series of estimates that would yield the correct answer if the estimates were correct. For example, we might make the following assumptions:  &lt;ul&gt; &lt;li&gt; &lt;div align="justify"&gt;There are approximately 5,000,000 people living in Chicago. &lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;On average, there are two persons in each household in Chicago. &lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;Roughly one household in twenty has a piano that is tuned regularly. &lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;Pianos that are tuned regularly are tuned on average about once per year. &lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;It takes a piano tuner about two hours to tune a piano, including travel time. &lt;/div&gt; &lt;li&gt; &lt;div align="justify"&gt;Each piano tuner works eight hours in a day, five days in a week, and 50 weeks in a year.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt; &lt;p align="justify"&gt;From these assumptions we can compute that the number of piano tunings in a single year in Chicago is  &lt;p align="justify"&gt;(5,000,000 persons in Chicago) / (2 persons/household) × (1 piano/20 households) × (1 piano tuning per piano per year) = 125,000 piano tunings per year in Chicago.  &lt;p align="justify"&gt;And we can similarly calculate that the average piano tuner performs  &lt;p align="justify"&gt;(50 weeks/year)×(5 days/week)×(8 hours/day)×(1 piano tuning per 2 hours per piano tuner) = 1000 piano tunings per year per piano tuner.  &lt;p align="justify"&gt;Dividing gives  &lt;p align="justify"&gt;(125,000 piano tuning per year in Chicago) / (1000 piano tunings per year per piano tuner) = 125 piano tuners in Chicago.  &lt;p align="justify"&gt;A famous example of a Fermi-problem-like estimate is the &lt;a href="http://en.wikipedia.org/wiki/Drake_equation"&gt;Drake equation&lt;/a&gt;, which seeks to estimate the number of intelligent civilizations in the galaxy. The basic question of why, if there are a significant number of such civilizations, ours has never encountered any others is called the &lt;a href="http://en.wikipedia.org/wiki/Fermi_paradox"&gt;Fermi paradox&lt;/a&gt;.  &lt;p align="justify"&gt;&lt;strong&gt;Design an evacuation plan for San Francisco&lt;/strong&gt;  &lt;p align="justify"&gt;Again, this one is all about the interviewer seeing how the interviewee would attack the problem. We'd start our answer by asking, "What kind of disaster are we planning for?"  &lt;p align="justify"&gt;&lt;strong&gt;How many times a day does a clock’s hands overlap?&lt;/strong&gt;  &lt;p align="justify"&gt;22 times, AM, 12, 1.05, 2.06 … 10.55, (11 times) and PM same number, so total 22 times.  &lt;p align="justify"&gt;&lt;strong&gt;Explain the significance of "dead beef"&lt;/strong&gt;  &lt;p align="justify"&gt;DEADBEEF is a hexadecimal value that has was used in debugging back in the mainframe/assembly days because it was easy to see when marking and finding specific memory in pages of hex dumps. Most computer science graduates have seen this at least in their assembly language classes in college and that's why they expect software engineers to know it.  &lt;p align="justify"&gt;&lt;strong&gt;A man pushed his car to a hotel and lost his fortune. What happened?&lt;/strong&gt;  &lt;p align="justify"&gt;He landed on Boardwalk. (Painful, right?)  &lt;p align="justify"&gt;&lt;strong&gt;You need to check that your friend, Bob, has your correct phone number but you cannot ask him directly. You must write the question on a card which and give it to Eve who will take the card to Bob and return the answer to you. What must you write on the card, besides the question, to ensure Bob can encode the message so that Eve cannot read your phone number?&lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;Since you are just "checking," you ask him to call you at a certain time. If he doesn't, he doesn't have your number. &lt;/p&gt; &lt;p align="justify"&gt;Too simple? A reader suggest: "In that case you need a check-sum. Have Bob add all the digits of your phone number together, write down the total, and pass that back to you."  &lt;p align="justify"&gt;&lt;strong&gt;You're the captain of a pirate ship, and your crew gets to vote on how the gold is divided up. If fewer than half of the pirates agree with you, you die. How do you recommend apportioning the gold in such a way that you get a good share of the booty, but still survive?&lt;/strong&gt;  &lt;p align="justify"&gt;You divide the booty evenly between the top 51% of the crew.  &lt;p align="justify"&gt;&lt;strong&gt;You have eight balls all of the same size, 7 of them weigh the same, and one of them weighs slightly more. How can you find the ball that is heavier by using a balance and only two weighing?&lt;/strong&gt;  &lt;p align="justify"&gt;Take 6 of the 8 balls and put 3 on each side of the scale. If the heavy ball isn't in the group of 6, you know it's one of the remaining 2 and so you put those two in the scale and determine which one. If the heavy ball is in the 6, you have narrowed it down to 3. Of those 3, pick any 2 and put them on the scale. If the heavy ball is in that group of 2, you know which one it is. If both balls are of equal weight, then the heavy ball is the one you sat to the side  &lt;p align="justify"&gt;&lt;strong&gt;You are given 2 eggs, You have access to a 100-story building. Eggs can be very hard or very fragile means it may break if dropped from the first floor or may not even break if dropped from 100th floor. Both eggs are identical. You need to figure out the highest floor of a 100-story building an egg can be dropped without breaking. The question is how many drops you need to make. You are allowed to break 2 eggs in the process&lt;/strong&gt;  &lt;p align="justify"&gt;The maximum egg drops for this method is 14 times. Instead of partitioning the floors by 10, Start at the 14th floor, and then go up 13 floors, then 12, then 11, then 10, 9, 8, 7, 6, 5, 4 until you get to the 99th floor, then here.&amp;nbsp; If the egg were to break at the 100th floor, it would take 12 drops (or 11 if you assume that it would break at the 100th floor).&amp;nbsp; Say, for example, that the 49th floor was the highest floor, the number of drops would be the 14th, 27th, 39th, 50th (the egg would break on the 50th floor) plus the 40, 41,42,43,44,45,46,47,48, and 49th floor for a total of 14 drops.  &lt;p align="justify"&gt;&lt;strong&gt;Explain a database in three sentences to your eight-year-old nephew&lt;/strong&gt;  &lt;p align="justify"&gt;The point here is to test the applicant's ability to communicate complex ideas in simple language. Here's our attempt, "A database is a machine that remembers lots of information about lots of things. People use them to help remember that information. Go play outside."  &lt;p align="justify"&gt;&lt;strong&gt;You are shrunk to the height of a nickel and your mass is proportionally reduced so as to maintain your original density. You are then thrown into an empty glass blender. The blades will start moving in 60 seconds. What do you do?&lt;/strong&gt;&lt;/p&gt; &lt;p align="justify"&gt;This one is all about the judging interviewee's creativity. We'd try to break the electric motor.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-8855434576106490234?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/8855434576106490234/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/google-interview-questions-that-makes.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8855434576106490234'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8855434576106490234'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/google-interview-questions-that-makes.html' title='Google Interview Questions that makes you feel stupid'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-8800029304853227567</id><published>2011-06-27T09:37:00.000-07:00</published><updated>2011-06-27T09:38:56.055-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Windows Live Writer'/><category scheme='http://www.blogger.com/atom/ns#' term='blogger tools'/><category scheme='http://www.blogger.com/atom/ns#' term='Issues'/><title type='text'>Windows Live Writer for Blog</title><content type='html'>&lt;p align="justify"&gt;I have been struggling to post into my blog from Microsoft Word 2007, as it would be a nightmare to write a article in word and format it once, and again do the same in Blogger, just because it has different formatting, and it cannot be a just copy paste for that matter.&lt;/p&gt; &lt;p align="justify"&gt;On a Monday evening, I wanted to post some stuff which went into few pages on the word, so I did not feel like formatting again on the blogger, after a an hour of research I understand that MS Word 2007 does not have full support for blogging from word, including picture, so its no point trying it.&lt;/p&gt; &lt;p align="justify"&gt;There is something called, Windows Live Writer, which is a MS tool which can be used to blog, which also supports adding pictures, So I downloaded and configured it, and this one is sample post from the Writer, and also to give some information about the live writer.&lt;/p&gt; &lt;p align="justify"&gt;Live writer comes with the Live essential tools, which comes free (mostly for legal version of windows). It can be downloaded from &lt;a href="http://explore.live.com/windows-live-writer?os=other"&gt;here&lt;/a&gt;. &lt;/p&gt; &lt;p align="justify"&gt;There is one thing you need to remember while configuring for the first time, do not give the blog address correctly, just give &lt;a href="http://text"&gt;http://text&lt;/a&gt;. Otherwise it seem to mess up things, later in steps things can be configured manually. So don’t worry. All the best. Happy Blogging. &lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-8800029304853227567?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/8800029304853227567/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/windows-live-writer-for-blog.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8800029304853227567'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8800029304853227567'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/windows-live-writer-for-blog.html' title='Windows Live Writer for Blog'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-5414714666871583923</id><published>2011-06-20T21:19:00.000-07:00</published><updated>2011-06-20T21:19:08.839-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='big endian'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><category scheme='http://www.blogger.com/atom/ns#' term='little endian'/><title type='text'>Big Endian and Little Endian</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;What is the difference between big endian and little endin machines&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;The data ordering at the memory is different for them, in little endian higher address have the most significant byte and lower have the least signifincant byte. and otherway round in case of big endian machines.&lt;br /&gt;&lt;br /&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;How do u determine a processor to be little endian or big endian, write a small program for it.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;"&gt;&lt;code&gt;int a = 1;&lt;br /&gt;if( *((char *)&amp;amp;a) == 1) &lt;br /&gt;    printf("Little endian");&lt;br /&gt;else&lt;br /&gt;    printf("Big Endian");&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;This can also be done using an eum as shown below &lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;"&gt;&lt;code&gt;&lt;br /&gt;enum&lt;br /&gt;{ &lt;br /&gt;  int a;&lt;br /&gt;  char c[4];&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;a = 1;&lt;br /&gt;if(char[1] == 1) &lt;br /&gt;    printf("Little Endian");&lt;br /&gt;else&lt;br /&gt;    printf("Big Endian");&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-5414714666871583923?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/5414714666871583923/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/big-endian-and-little-endian.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5414714666871583923'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5414714666871583923'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/big-endian-and-little-endian.html' title='Big Endian and Little Endian'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-5800930709943733273</id><published>2011-06-09T06:41:00.001-07:00</published><updated>2011-06-19T04:15:51.104-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='algorithm'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>Traverse a tree without recursion</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div&gt;The basic problem of traversing a tree requires recursion. If you dont have recursion then you should have a mechanism to save either side of the tree on to a temporary location, this can be done with a stack. &lt;br /&gt;So the algorithm should be&lt;br /&gt;&lt;br /&gt;1) traverse the node, if there is right push on to stack, and go to left node&lt;br /&gt;2) if there is no left then pop from the stack and go to that node. &lt;br /&gt;3) do this til all the nodes are exhausted. i.e. till your node pointer is null&lt;br /&gt;&lt;br /&gt;Find the code here, for your reference. Push and Pop can be implemented as a simple stack methods.&lt;br /&gt;&lt;br /&gt;&lt;pre style="font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; color: #000000; background-color: #eee;font-size: 12px;border: 1px dashed #999999;line-height: 14px;padding: 5px; overflow: auto; width: 100%"&gt;&lt;code&gt;/* Traverse a tree without recursion */&lt;br /&gt;/* The basic idea is to use a stack for storing the other side of the tree when going in one direction */&lt;br /&gt;&lt;br /&gt;void traverse_without_recursion(node *head) {&lt;br /&gt;    node *next = head;&lt;br /&gt;    while(next != NULL) {&lt;br /&gt;        printf(&amp;quot;%d&amp;quot;, next-&amp;gt;data);&lt;br /&gt;        if(next-&amp;gt;right)&lt;br /&gt;            PUSH((int)(next-&amp;gt;right));&lt;br /&gt;        if(next-&amp;gt;left)&lt;br /&gt;            next = next-&amp;gt;left;&lt;br /&gt;        else next = (node *) POP();&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-5800930709943733273?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/5800930709943733273/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/traverse-tree-without-recursion.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5800930709943733273'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5800930709943733273'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/traverse-tree-without-recursion.html' title='Traverse a tree without recursion'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-4011758325884649397</id><published>2011-06-09T06:29:00.001-07:00</published><updated>2011-06-18T05:22:31.862-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='algorithm'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>Write a program to find the max and second max</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;This is little tricky, but not difficult. easiest way to do this is to sort the array and then find the answer. But that not expected out of you.&lt;br /&gt;&lt;br /&gt;The algorithm here is take thefirst element as the max and second max. Then loop through all elements&lt;br /&gt;&lt;br /&gt;&lt;ol style="text-align: left;"&gt;&lt;li&gt;If the number is larger than max then make it max, and make old max to second max.&lt;/li&gt;&lt;li&gt;Else if it is more than second max then make it the second max.&lt;/li&gt;&lt;li&gt;In all other cases drop that number&lt;/li&gt;&lt;/ol&gt;Here goes the code for your reference.&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;pre style="background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;"&gt;&lt;code&gt;/*&lt;br /&gt;** Write a program for finding the max and second max &lt;br /&gt;** of an array of given size */&lt;br /&gt;&lt;br /&gt;#define SIZE 10&lt;br /&gt;&lt;br /&gt;int main(void)&lt;br /&gt;{&lt;br /&gt;    int array[SIZE] = {10, 5, 16, 2, 1, 2, 3, 18, 21, 4};&lt;br /&gt;    int i, max, sec_max;&lt;br /&gt;&lt;br /&gt;    max  = sec_max = array[0];&lt;br /&gt;&lt;br /&gt;    for(i=0; i&amp;lt; SIZE; i++)&lt;br /&gt;    {&lt;br /&gt;        if(array[i] &amp;gt; max) {&lt;br /&gt;            sec_max = max;&lt;br /&gt;            max = array[i];&lt;br /&gt;        }&lt;br /&gt;        else if(array[i] &amp;gt; sec_max)&lt;br /&gt;            sec_max = array[i];&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;    printf("max =  %d, sec max = %d", max, sec_max);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-4011758325884649397?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/4011758325884649397/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/write-program-to-find-max-and-second.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4011758325884649397'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4011758325884649397'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/write-program-to-find-max-and-second.html' title='Write a program to find the max and second max'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-5025036290737118455</id><published>2011-06-04T02:57:00.000-07:00</published><updated>2011-06-15T11:16:24.256-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows 7'/><category scheme='http://www.blogger.com/atom/ns#' term='Outlook'/><category scheme='http://www.blogger.com/atom/ns#' term='Issues'/><title type='text'>Error message when you click a hyperlink in Outlook</title><content type='html'>&lt;div&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;Today morning, When I open my outlook for joining a meeting, I was not able to click the link for meeting, it was working when I pasted the same on browser, &amp;nbsp;When you click a&amp;nbsp;hyper link&amp;nbsp;in Microsoft Outlook, you may receive the following error message: &lt;i&gt;"This operation has been cancelled due to restrictions in effect on this computer. Please contact your system administrator."&lt;/i&gt; I was clueless as everything was working fine a day before. Did some search on google and found that microsoft has published a solution for the same.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;This was said to be a problem due to some corrupted registry keys after the internet explorer upgrade, and there is patch executable released by microsoft which would fix the problem for you, check this &lt;a href="http://support.microsoft.com/?kbid=310049#fixit4me"&gt;link&lt;/a&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;If you find any issues after this, do let me now :)&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-5025036290737118455?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/5025036290737118455/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/error-message-when-you-click-hyperlink.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5025036290737118455'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5025036290737118455'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/error-message-when-you-click-hyperlink.html' title='Error message when you click a hyperlink in Outlook'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-1676284067262444339</id><published>2011-06-01T23:02:00.000-07:00</published><updated>2011-06-04T02:50:13.899-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows 7'/><category scheme='http://www.blogger.com/atom/ns#' term='Windows'/><category scheme='http://www.blogger.com/atom/ns#' term='Issues'/><category scheme='http://www.blogger.com/atom/ns#' term='Mouse Scroll'/><category scheme='http://www.blogger.com/atom/ns#' term='Picasa'/><title type='text'>Fix for Scroll Issue with Picasa 3.8 on Windows 7</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;Recently I faced a strange issue with picasa, the photo organizer/editor from Google. The scroll does not work !!, It was working perfectly fine on my personal laptop, but was not working on my office laptop, and scroll works fine in rest of the applications. I was thinking there is something to do with the installation, but reinstall also did not solve the problem,&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Later I found that, Most (almost all) mouse drivers cause mouse wheel events with a "delta" of ±120. This is an arbitrary value that has been choosen by Microsoft in the past to allow finer control.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Since then, several programs use that value directly to test whether the mouse has been scrolled down or up (delta / 120 == 1 -&amp;gt; down, delta / 120 == -1 -&amp;gt; up, or something like that).&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;However, the Intellipoint software causes mouse wheel events with smaller "delta" value (the expected finer grain control), and programs which use the 120 value that way just fail to register the wheel movement, because in integral values, 30 / 120 = 0...&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Let's hope Picasa developers would fix this issue soon, by modifying the mouse wheel handling method.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;There are ways you can fix this issue temporarily, one is by using the Autohotkey. Autohotkey is a program you run in the background, which loads simple or complex scripts controlling the mouse and keyboard inputs, as well as other wanted behaviors in your Windows system. You can intercept the mouse wheel event and change the delta value before passing to a particular program, so if you make it 120 again, you would solve the issue.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;ol&gt;&lt;li&gt;Download and install AutoHotkey (http://www.autohotkey.com)&lt;/li&gt;&lt;li&gt;Right-click an empty spot on your desktop or in a folder of your choice.&lt;/li&gt;&lt;li&gt;In the menu that appears, select New -&amp;gt; AutoHotkey Script. (Alternatively, select New -&amp;gt; Text Document.)&lt;/li&gt;&lt;li&gt;Type a name for the file, ensuring that it ends in .ahk. For example: Test.ahk&lt;/li&gt;&lt;li&gt;Right-click the file and choose Edit Script.&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;In the window that appears (likely Notepad), copy the lines of the script above. Save your document.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;AutoHotkey does not run by itself, it runs a script. So you need to put the script file you just created in Startup, and it will start automatically when Windows start. This should fix your mousewheel problems with Picasa.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;I have found that the latest IntelliPoint 8.0 software (released August 2010) fixes the scrolling issue. It also does the same thing, it detects that the picasa is running and changes the delta value to 120 and things would work just perfct&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;You can download the latest version of Intellipoint software for your mouse from &lt;a href="http://www.microsoft.com/hardware/download/download.aspx?category=MK"&gt;here&lt;/a&gt;,&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-1676284067262444339?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/1676284067262444339/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/fix-for-scroll-issue-with-picasa-38-on.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1676284067262444339'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1676284067262444339'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/06/fix-for-scroll-issue-with-picasa-38-on.html' title='Fix for Scroll Issue with Picasa 3.8 on Windows 7'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-7587398179352891203</id><published>2011-01-22T09:01:00.000-08:00</published><updated>2011-01-22T09:01:40.628-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='activation'/><category scheme='http://www.blogger.com/atom/ns#' term='activation without product key'/><category scheme='http://www.blogger.com/atom/ns#' term='windows xp mode'/><category scheme='http://www.blogger.com/atom/ns#' term='product key'/><title type='text'>How to Activate Windows XP without Product Key</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;Here is a simple trick to activate windows without any product key &amp;nbsp;.&lt;br /&gt;&lt;br /&gt;When you have installed windows xp and try to activate you get messages like “your product key is not genuine or the number of activation has been exceeded” and then it tells you to call MIcrosoft to get the key, Instead of Going to this trouble, or instead of spending Hundred of dollars, to get a new genuine product, let us solve this problem by following way:&lt;br /&gt;&lt;br /&gt;STEPS:-&lt;br /&gt;&lt;br /&gt;&lt;ol style="text-align: left;"&gt;&lt;li&gt;Click on Start&lt;/li&gt;&lt;li&gt;Find and Click “Run”&lt;/li&gt;&lt;li&gt;Type regedit&lt;/li&gt;&lt;li&gt;Click the plus next to “HKEY_LOCAL_MACHINE”&lt;/li&gt;&lt;li&gt;Click the plus next to “SOFTWARE”&lt;/li&gt;&lt;li&gt;Click the plus next to “Microsoft”&lt;/li&gt;&lt;li&gt;Click the plus next to “Windows NT”&lt;/li&gt;&lt;li&gt;Click the plus next to “CurrentVersion”&lt;/li&gt;&lt;li&gt;Click “WPAEvents”&lt;/li&gt;&lt;li&gt;On the right panel, find “OOBETimer” then double click it.&lt;/li&gt;&lt;li&gt;Now, Delete all the Values by highlighting it, then delete it&lt;/li&gt;&lt;li&gt;Then type in this value without the quotation mark “FF D5 71 D6 8B 6A 8D 6F D5 33 93 FD”&lt;/li&gt;&lt;li&gt;Then after that click OK,&lt;/li&gt;&lt;li&gt;Then on the left panel right click WPAEvents, then click on permissions&lt;/li&gt;&lt;li&gt;Then click System or SYSTEM, then Deny Full Control, then Click OK.&lt;/li&gt;&lt;li&gt;Then Exit Registry Editor by Click the X or the red X on the Upper Right of the Title Bar or press ALT and F4 at the same time.&lt;/li&gt;&lt;li&gt;To Very that it works, go to start, then “activate windows”, or go to start, then all programs, then “activate windows”&lt;/li&gt;&lt;li&gt;If it says that Windows has been activated.&lt;/li&gt;&lt;/ol&gt;&lt;div&gt;I got this info from &lt;a href="http://tech18.com/how-to-activate-windows-xp-without-product-key.html"&gt;this website&lt;/a&gt;, thanks a ton to him&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-7587398179352891203?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/7587398179352891203/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/01/how-to-activate-windows-xp-without.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7587398179352891203'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7587398179352891203'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/01/how-to-activate-windows-xp-without.html' title='How to Activate Windows XP without Product Key'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-1245386002979344845</id><published>2011-01-22T08:57:00.000-08:00</published><updated>2011-01-22T08:57:52.882-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='virtual pc 2007'/><category scheme='http://www.blogger.com/atom/ns#' term='windows xp mode'/><category scheme='http://www.blogger.com/atom/ns#' term='virtual pc'/><category scheme='http://www.blogger.com/atom/ns#' term='virtual hard disk'/><title type='text'>XP Mode for Windows 7 Ultimate</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div style="text-align: justify;"&gt;XP mode is nothing but, a virtual machine inside windows 7 running windows xp. The best part I can think about this is everything is provided by Microsoft, the virtual machine and the guest operating system, and hence we assume the operating system to be tuned for virtual machine and hence the performance is much better. Last year &amp;nbsp;I had run windows xp on Ubuntu, and this time on Windows 7. The main motive for me to try this is I wanted to run Need for speed Special Edition, it was one of my favorite game of the past.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/_O-y4iQ3ddz4/TTsMG3mlgNI/AAAAAAAAFZE/OAqlLYZi944/s1600/Fullscreen+capture+1222011+102442+PM.bmp" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="250" src="http://4.bp.blogspot.com/_O-y4iQ3ddz4/TTsMG3mlgNI/AAAAAAAAFZE/OAqlLYZi944/s400/Fullscreen+capture+1222011+102442+PM.bmp" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;You need to have a genuine windows 7 for you to be able to install xp mode, but then you can download the &lt;a href="http://thepiratebay.org/torrent/5663221/Windows_XP_Mode_For_Windows_7"&gt;torrent version&lt;/a&gt; of the same files as it by pass the genuine validation check. I downloaded one from a torrent, which has Windows Xp mode installer, and Vitual PC and Virtual PC update. I installed Windows Xp mode, which basically is a VHD (Virtual Hard Disk) file, which can be booted from Virtual PC. I could not install Virtual PC as it was meant for a 64 bit machine and mine was 32 bit machine, so I downloaded Virtual PC 2007, and it works just fine with the VHD Image installed by the Xp mode.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;I think the Virtual PC provides additional functionality which allows you to run Xp installed applications directly from windows 7, which you cannot do here directly, but you can always go inside xp and run the applications. Things seem to be working very fine for me. I also installed the guest additions which allows you to share folders between the operating systems and also allows pointer integration.&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-1245386002979344845?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/1245386002979344845/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/01/xp-mode-for-windows-7-ultimate.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1245386002979344845'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1245386002979344845'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2011/01/xp-mode-for-windows-7-ultimate.html' title='XP Mode for Windows 7 Ultimate'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_O-y4iQ3ddz4/TTsMG3mlgNI/AAAAAAAAFZE/OAqlLYZi944/s72-c/Fullscreen+capture+1222011+102442+PM.bmp' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-3535487253973333960</id><published>2010-12-15T06:05:00.000-08:00</published><updated>2010-12-15T06:06:01.796-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='VGP-VCC6'/><category scheme='http://www.blogger.com/atom/ns#' term='Sony Vaio'/><category scheme='http://www.blogger.com/atom/ns#' term='device driver'/><category scheme='http://www.blogger.com/atom/ns#' term='Web Cam'/><category scheme='http://www.blogger.com/atom/ns#' term='Ricoh'/><title type='text'>Sony VAIO Camera Driver for Ubuntu</title><content type='html'>&lt;div style="text-align: justify;"&gt;After installing Ubuntu and configuring it to look like windows, one thing that was really lacking was the web cam driver, I could not do video call from Gmail. This time with little easy, I found a link which help to install the driver easily.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;First check which is your camera, by typing in the command lsusb, which shows something below.&lt;/div&gt;&lt;div&gt;&lt;pre style="background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;"&gt;&lt;code&gt;Bus 006 Device 002: ID 045e:00a4 Microsoft Corp. &lt;br /&gt;Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub&lt;br /&gt;Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub&lt;br /&gt;Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub&lt;br /&gt;Bus 003 Device 005: ID 044e:3012 Alps Electric Co., Ltd &lt;br /&gt;Bus 003 Device 004: ID 044e:3013 Alps Electric Co., Ltd &lt;br /&gt;Bus 003 Device 003: ID 044e:3010 Alps Electric Co., Ltd Bluetooth Adapter&lt;br /&gt;Bus 003 Device 002: ID 044e:3011 Alps Electric Co., Ltd &lt;br /&gt;Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub&lt;br /&gt;Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub&lt;br /&gt;Bus 001 Device 003: ID 05ca:1839 Ricoh Co., Ltd Visual Communication Camera VGP-VCC6 [R5U870]&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;div style="text-align: justify;"&gt;&lt;i&gt;The camera is from Ricoh Co. Ltd, VGP-VCC6[R5U870]&amp;nbsp;&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;i&gt;&lt;/i&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;The packages provided (both source and binary) include only the loader software and do not contain the microcode, whose copyright and license status is unclear. Instead, a simple shell script is provided that can download and install the microcode directly from the upstream repository.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Installation&lt;/div&gt;&lt;div style="text-align: justify;"&gt;========&lt;/div&gt;&lt;div style="text-align: justify;"&gt;1. sudo add-apt-repository ppa:r5u87x-loader/ppa&lt;/div&gt;&lt;div style="text-align: justify;"&gt;2. sudo apt-get update&lt;/div&gt;&lt;div style="text-align: justify;"&gt;3. sudo apt-get install r5u87x&lt;/div&gt;&lt;div style="text-align: justify;"&gt;4. sudo /usr/share/r5u87x/r5u87x-download-firmware.sh&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;(Step 1 only works on Ubuntu 9.10 and newer. On 8.04 you will need to add this PPA to your APT sources manually.)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Supported hardware&lt;/div&gt;&lt;div style="text-align: justify;"&gt;================&lt;/div&gt;&lt;div style="text-align: justify;"&gt;05ca:1803 Flybook V5&lt;/div&gt;&lt;div style="text-align: justify;"&gt;05ca:1810 HP Pavilion Webcam&lt;/div&gt;&lt;div style="text-align: justify;"&gt;05ca:1835 Sony Camera VGP-VCC5 (used on Sony Vaio SZ laptops)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;05ca:1836 Sony Camera VGP-VCC4 (used on Sony Vaio FE laptops)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;05ca:1837 Sony Camera VGP-VCC4 (used on Sony Vaio FZ laptops)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;05ca:1839 Sony Camera VGP-VCC6 (used on Sony Vaio CR laptops)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;05ca:183a Sony Camera VGP-VCC7 (used on Sony Vaio SZ and TZ11 laptops)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;05ca:183b Sony Camera VGP-VCC8 (used on Sony Vaio FZ laptops)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;05ca:183e Sony Camera VGP-VCC9 (used on Sony Vaio FZ laptops)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Hope this helps !&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-3535487253973333960?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/3535487253973333960/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/sony-vaio-camera-driver-for-ubuntu.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3535487253973333960'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3535487253973333960'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/sony-vaio-camera-driver-for-ubuntu.html' title='Sony VAIO Camera Driver for Ubuntu'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-9223216068380519792</id><published>2010-12-13T19:58:00.000-08:00</published><updated>2010-12-15T05:47:07.291-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows 7 theme for ubuntu'/><category scheme='http://www.blogger.com/atom/ns#' term='make ubuntu look like windows 7'/><title type='text'>Make Ubuntu look like Windows 7 (Windows 7 theme for Ubuntu)</title><content type='html'>&lt;div style="text-align: justify;"&gt;Most of my time on my laptop is going to be on Ubuntu-10.10 from now on. But I am a hard core fan of Microsoft and its Windows OS. The best ever OS you can ever have on your personal laptop at this point of time in my opinion for 100s of reasons, but whatever is the case when you want to get into learning mode, things are in&amp;nbsp;favor of Linux, as its open source and you can download, modify, configure and compile your own kernel. and write your own drivers etc.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;So while I am inside Linux, I don't want to miss the familiar look of Windows 7, So I spent some time to set my Ubuntu look like Windows 7, and there is lot more you can do, but I want to keep it to the minimum and internally it should have the Linux touch to it. So here is the list of things I did, and if I add any more I will update in the Updates section.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;ol&gt;&lt;li&gt;Install emerald theme manager, and download Windows 7 theme for it.&lt;br /&gt;goto synaptic theme manager, and search for emerald and install it and all dependencies. Download the theme for windows 7 from &lt;a href="http://www.gnome-look.org/content/show.php/Who+Needs+Windows+7+%3F?content=105399"&gt;here.&lt;/a&gt;&amp;nbsp;Open emerald theme manager and import the downloaded theme. Alt+f2 -&amp;gt; type in command &lt;i&gt;emerald --replace&lt;/i&gt;&lt;/li&gt;&lt;li&gt;Move the task bar down, and delete the other bar, which is having minimum buttons, (don't worry, you are not going to loose it forever, its configurable)&lt;/li&gt;&lt;li&gt;Add emerald to start up when Ubuntu starts, same command as above.&lt;/li&gt;&lt;li&gt;Goto Themes, customize, change Icons to Windows 7 set of icons, which are already present by now in the&amp;nbsp;Appearance settings.&lt;/li&gt;&lt;li&gt;Set a bright windows 7 wall paper.&lt;/li&gt;&lt;li&gt;Press Alt + F2 -&amp;gt; type in &lt;i&gt;gconf-editor, &lt;/i&gt;goto apps-&amp;gt;nautilus-&amp;gt;Desktop, and look for the trash_icon_visible and check the box beside, you can also add other icons to desktop like computer etc, I don't like My computer icon on my desktop !&lt;/li&gt;&lt;li&gt;Download the task bar background image from &lt;a href="http://img.photobucket.com/albums/v173/Zeldamo/Stbr2.png"&gt;here&lt;/a&gt;, and change the task bar settings to put this image as the background image.&lt;/li&gt;&lt;li&gt;Download the Show Desktop background &lt;a href="http://img.photobucket.com/albums/v173/Zeldamo/ShowDesktop2.png"&gt;image&lt;/a&gt;, and add code for it.&amp;nbsp;The code looks something like this, &amp;nbsp;You may have to install wmctl package for this.&lt;/li&gt;&lt;pre style="background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;"&gt;&lt;code&gt;#!/bin/sh&lt;br /&gt;if wmctrl -m | grep "mode: ON"; then&lt;br /&gt;exec wmctrl -k off&lt;br /&gt;else&lt;br /&gt;exec wmctrl -k on&lt;br /&gt;fi&lt;/code&gt;&lt;/pre&gt;&lt;li&gt;You can change the three menu task bar with single icon start button type task bar, but removing that panel (right click - remove) then add to panel &lt;i&gt;Main Menu.&amp;nbsp;&lt;/i&gt; &lt;/li&gt;&lt;li&gt;You download the Windows 7 icons set from &lt;a href="http://www.4shared.com/file/162130180/d789e5b7/Windows_7_iconstar.html"&gt;this link&lt;/a&gt;, and apply it by drag and dropping on the change themes dialog box.&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/_O-y4iQ3ddz4/TQdyF7qgkwI/AAAAAAAAFXA/Jy_oOazgY7w/s1600/ubuntu_windows7.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="250" src="http://1.bp.blogspot.com/_O-y4iQ3ddz4/TQdyF7qgkwI/AAAAAAAAFXA/Jy_oOazgY7w/s400/ubuntu_windows7.png" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;You are done !, now your desktop should look something like this, its more of windows 7, &amp;nbsp;with a touch of Linux for the menus. I have referred to these two sites for this make over, and some more from Google! Other things explained on these blogs, I found&amp;nbsp;unnecessary&amp;nbsp;for me&amp;nbsp;at least.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;(a) &lt;a href="http://my.opera.com/ubuntunerd1/blog/how-to-make-ubuntu-look-like-windows7"&gt;My Opera&lt;/a&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;(b) &lt;a href="http://aminesoft.wordpress.com/2009/03/04/make-your-gnome-like-windows-7/"&gt;Aminesoft's Blog&lt;/a&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Comments are welcome !&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-9223216068380519792?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/9223216068380519792/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/make-ubuntu-look-like-windows-7-windows.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/9223216068380519792'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/9223216068380519792'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/make-ubuntu-look-like-windows-7-windows.html' title='Make Ubuntu look like Windows 7 (Windows 7 theme for Ubuntu)'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_O-y4iQ3ddz4/TQdyF7qgkwI/AAAAAAAAFXA/Jy_oOazgY7w/s72-c/ubuntu_windows7.png' height='72' width='72'/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-8494346687543583826</id><published>2010-12-13T19:39:00.000-08:00</published><updated>2010-12-14T05:22:02.271-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='syntax error eclipse'/><title type='text'>Disable Syntax Error Check in Eclipse</title><content type='html'>Eclipse underlines when your code does not match the syntax rules, which is done in the CDT parser, for lot of reasons you end up highlighting most of your code as syntax error and its a pain to see the code in between these high lights, I wanted to disable it for god's sake! and could not find an easy menu option to do tat. After Google-ing a bit, I found it can be by un-checking these options shown in the below pictures.&lt;br /&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/_O-y4iQ3ddz4/TQduwKOAK8I/AAAAAAAAFW8/cVsrWkiLWrE/s1600/syntax_error.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="187" src="http://2.bp.blogspot.com/_O-y4iQ3ddz4/TQduwKOAK8I/AAAAAAAAFW8/cVsrWkiLWrE/s400/syntax_error.png" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;Goto Windows-&amp;gt;Preferences-&amp;gt;General-&amp;gt;Editors-&amp;gt;Text Editors-&amp;gt;Annotations-&amp;gt;C/C++ Occurrences, and uncheck all the boxes on the right side and apply ! Hope this helps !&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-8494346687543583826?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/8494346687543583826/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/disable-syntax-error-check-in-eclipse.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8494346687543583826'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8494346687543583826'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/disable-syntax-error-check-in-eclipse.html' title='Disable Syntax Error Check in Eclipse'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_O-y4iQ3ddz4/TQduwKOAK8I/AAAAAAAAFW8/cVsrWkiLWrE/s72-c/syntax_error.png' height='72' width='72'/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-2601515108809504711</id><published>2010-12-12T09:20:00.000-08:00</published><updated>2010-12-12T09:20:05.319-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='device driver'/><category scheme='http://www.blogger.com/atom/ns#' term='makefile'/><category scheme='http://www.blogger.com/atom/ns#' term='eclipse'/><title type='text'>Compile Device Driver for Linux in Eclipse</title><content type='html'>&lt;div style="text-align: justify;"&gt;There is an easy way to compile device driver in Linux using eclipse, once its been setup life becomes much easy, as you don't have to switch between the editor and the command shell every time you need to change something,&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Here is the screen shot of my project, Look at it carefully, all you need to add to the project are main.c and a makefile. rest are the result of compilation. makefile will only contain one line &lt;i&gt;obj-m := main.o&lt;/i&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/_O-y4iQ3ddz4/TQUC6LRtToI/AAAAAAAAFW4/rXCZv-1fGbU/s1600/DD_eclipse.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em; text-align: justify;"&gt;&lt;img border="0" height="343" src="http://2.bp.blogspot.com/_O-y4iQ3ddz4/TQUC6LRtToI/AAAAAAAAFW4/rXCZv-1fGbU/s400/DD_eclipse.png" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Most of the things remain same for the simple C project as mentioned in the previous post, after creating the project, you need to change the command to build the project as,&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;i&gt;make -C /usr/src/linux-headers-2.6.35-22-generic M=$(PWD) modules&lt;/i&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;The path given above is my linux kernel header file path, change to yours accordingly. After this, you set the build directory to the directory of your source code for device drivers. And in the behavior tab, remove the all from build command line, other wise it will crib saying could not find rule to build all !!&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Thats it, you are ready to use the Eclipse IDE for device driver development, all the best !&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-2601515108809504711?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/2601515108809504711/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/compile-device-driver-for-linux-in.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2601515108809504711'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2601515108809504711'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/compile-device-driver-for-linux-in.html' title='Compile Device Driver for Linux in Eclipse'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_O-y4iQ3ddz4/TQUC6LRtToI/AAAAAAAAFW4/rXCZv-1fGbU/s72-c/DD_eclipse.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-3132810537634906623</id><published>2010-12-12T08:23:00.000-08:00</published><updated>2010-12-12T08:23:50.779-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux kernel'/><category scheme='http://www.blogger.com/atom/ns#' term='gdb server'/><category scheme='http://www.blogger.com/atom/ns#' term='qemu'/><category scheme='http://www.blogger.com/atom/ns#' term='eclipse'/><category scheme='http://www.blogger.com/atom/ns#' term='debugging'/><category scheme='http://www.blogger.com/atom/ns#' term='compile'/><title type='text'>Compiling Linux Kernel in eclipse, and debugging using QEMU</title><content type='html'>&lt;div style="text-align: justify;"&gt;After I have started working with this eclipse IDE, I came across an article in a blog, and found it very interesting. The fact that compiling Linux kernel is fairly easy on the terminal does not need it to be compiled somewhere else, but then the fact that once configured, if you are using eclipse as an IDE for modifying and browsing the source code, it would be&amp;nbsp;beneficial&amp;nbsp;if you can directly build from there.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;The procedure is very simple in fact !&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Download the latest version of kernel from kernel.org website (ftp) and extract it to where ever you want to. The latest version now is (2.6.36.2), so download the linux-2.6.36.2.tar.gz file from ftp, and copy it to you home directory (in my case prasad)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;tar xzvf linux-2.6.36.2.tar.gz&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Now build the kernel, after configuring, and make sure it builds fine when built from the command prompt. Now its easy to integrate this environment into eclipse, this is almost same my previous post of building a make file based c project to build in eclipse. But it just looks complicated because its kernel.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Create a new make file based C project ans select the kernel source directory to be your project directory and select other tool chain option for tool chain. Click finish, I hope you have disabled indexing and auto build.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Now, go to project properties and update the build directory path, and build command as needed, if you are building kernel in the same directory as the source code, you don't have to change anything here, but in case out put directory is different then just update the command as&amp;nbsp;&lt;i&gt;make O=/build/linux-2.6-xxx &lt;/i&gt;and build directory to &lt;i&gt;/build/linux-2.6-xxx.&lt;/i&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;If you were building for a different target other than x86, update the Makefile of linux kernel with the &lt;i&gt;CROSS_COMPILE and ARCH,&lt;/i&gt; or you can as well give them in the make command also.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Now click build all, you can see that eclipse IDE runs the commands set and outputs of the compilations are seen on eclipse console. if there is any error, you can just double click and the corresponding source code is highlighted (this is the best part of using an IDE)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Now you are ready to connect to QEMU for debugging the kernel, locate you&lt;i&gt; bzImage/zImage&lt;/i&gt;, (kernel binary), run the kernel in QEMU, refer to qemu manual for how to do that (!?)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;for your reference, in case of x86 kernel to be run on the QEMU type in this command (I assume qemu is compiled and installed)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;i&gt;qemu -hda /dev/zero -kernel ~/linux-2.6.32.2/arch/i386/boot/bzImage -s -S&lt;/i&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;-s -S options make the qemu wait on the TCP connection at port 1234 for the gdb debugger to connect.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Now in the eclipse IDE, go to &lt;i&gt;Run-&amp;gt;Debug Configurations&lt;/i&gt;, double click on C/C++ application, a new configuration will be created. Browse the &lt;i&gt;project&lt;/i&gt;, and in C/C++ application field browse the &lt;i&gt;vmlinux&lt;/i&gt; for your kernel, and set the path for it. In the debugger tab, select the&lt;i&gt; gdb-server&lt;/i&gt;, and set the stop point to be &lt;i&gt;start_kernel. &lt;/i&gt;In the connections tab, set it to &lt;i&gt;TCP and 1234&lt;/i&gt; port number, and you are ready for debugging.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;The whole thing is explained in detail in the blog post &lt;a href="http://issaris.blogspot.com/2007/12/download-linux-kernel-sourcecode-from.html"&gt;here&lt;/a&gt;, Thanks for the wonderful information, it was really helpful for me. I myself debugged kernel using this approach in eclipse, if anybody faced problem let me know, I am glad to help you out.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-3132810537634906623?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/3132810537634906623/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/compiling-linux-kernel-in-eclipse-and.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3132810537634906623'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3132810537634906623'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/compiling-linux-kernel-in-eclipse-and.html' title='Compiling Linux Kernel in eclipse, and debugging using QEMU'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-1851836900711131083</id><published>2010-12-11T05:01:00.000-08:00</published><updated>2010-12-11T05:01:56.026-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='c++'/><category scheme='http://www.blogger.com/atom/ns#' term='makefile'/><category scheme='http://www.blogger.com/atom/ns#' term='eclipse'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><category scheme='http://www.blogger.com/atom/ns#' term='compile'/><title type='text'>Compile C/C++ code in eclipse using makefiles</title><content type='html'>In Linux, usually compilation is done using makefiles, run in command shell. I use to work on Linux kernel, and in such cases, I use to setup a Samba server for editing and source code browsing was done in windows. But then now I am using only one PC, which is a dual boot for windows and Ubuntu Linux, so I cannot have samba server. I was looking for a IDE in Linux, and found eclipse to be very useful.&lt;br /&gt;&lt;br /&gt;I wasn't very familiar with the eclipse IDE and I was trying to setup the compilation using makefiles, initially I had some hiccups but could later configure it easily after generating an example C project from it and following similar methods to write the makefiles.&lt;br /&gt;&lt;br /&gt;Here is the method to do it, so it might come handy to you in case if you are trying to use eclipse IDE for compiling C/C++ project using make files.&lt;br /&gt;&lt;br /&gt;First create a empty C/C++ project, makefile project, and select the --other tool chain--. keep the project settings to default, as shown in the below figure. Click finish.&lt;br /&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/_O-y4iQ3ddz4/TQN0clOHk5I/AAAAAAAAFWw/350EzBOSBdY/s1600/Screenshot.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="381" src="http://1.bp.blogspot.com/_O-y4iQ3ddz4/TQN0clOHk5I/AAAAAAAAFWw/350EzBOSBdY/s400/Screenshot.png" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;Once project is created, as a C file, and a 'makefile'. The makefile tells the make program about how the project should be built, I am giving here the sample make file for the simple HelloWorld.c, which you can further extend as per your use.&lt;br /&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/_O-y4iQ3ddz4/TQN1aqbEwvI/AAAAAAAAFW0/BivGDdYw27s/s1600/makefile.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="313" src="http://4.bp.blogspot.com/_O-y4iQ3ddz4/TQN1aqbEwvI/AAAAAAAAFW0/BivGDdYw27s/s320/makefile.png" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-1851836900711131083?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/1851836900711131083/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/compile-cc-code-in-eclipse-using.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1851836900711131083'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1851836900711131083'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/compile-cc-code-in-eclipse-using.html' title='Compile C/C++ code in eclipse using makefiles'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_O-y4iQ3ddz4/TQN0clOHk5I/AAAAAAAAFWw/350EzBOSBdY/s72-c/Screenshot.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-1951686357486854128</id><published>2010-12-08T10:01:00.000-08:00</published><updated>2010-12-08T19:50:42.011-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows 7'/><category scheme='http://www.blogger.com/atom/ns#' term='Ubuntu 10.10'/><category scheme='http://www.blogger.com/atom/ns#' term='Dual boot'/><title type='text'>Setting up Dual boot for Windows 7 and Ubuntu 10.10</title><content type='html'>&lt;div style="text-align: justify;"&gt;Recently I have updated to windows 7 and so, I have dumped my ubuntu (8.04), and did not install until I actually needed one for some programming purpose. Now it was time for installation. It was very straight forward last time when I did it, so did not bother to check any how to do it online, and more over installing operating system wasn't a new topic for me, and have done dual booting many time before also.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;But this time the purpose was different, I wanted to make it install on an USB with&amp;nbsp;persistence, I got some link to do that, it was very promising, but when I ran from that, ubuntu was crashing very often, most of the programs were not working as expected, so then I thought of installing it on hard disk after confirming that the iso image I downloaded is good by booting it on a virtual machine.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;When started with installation, there was surprise for me, the disk utility was very confusing, it was asking too many questions as to whether the partition should be from&amp;nbsp;beginning or at end etc, and also where the grub boot loader should be installed etc. So I was a bit confused and installed the boot loader on the same partition on which windows boot driver was installed, and it was a mistake, and things did not work, and windows also did not boot, I could only boot ubuntu. But then I was sure that the windows installation is intact, so I put the windows disc and then repaired it, and it worked for me. But because of some updates I started getting error on windows saying that "you are victim of software&amp;nbsp;counterfeit.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;I gone through web pages now to find out what needs to be done for making a dual boot with Windows 7 and Ubuntu 10.0, and found that Windows 7 messes up with the grub boot loaded when windows is updated, so we need to make sure that boot loader should be installed on the same drive as boot partition of ubuntu, and then, using EasyBCD program in windows we can configure windows boot loader to boot Linux from the ubuntu installed partition.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;I had problem partitioning 4 partitions for linux using their disk tool, so I did that from windows disk management tool, and then during installation selected them, and it worked fine for me. The partitions you need are boot (500mb, primary, ext4, /boot), root (3gb+, logical, ext4, /), swap (1gb), home (remaining, how much ever you wish, ext4, logical). You are done.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;EasyBCD is a free software and easy to use also, download, install and configure using the easy to use user interface. Hope it helps. I have not put any screen shots as this much details seems to be enough, and if needed refer to &lt;a href="http://www.linuxbsdos.com/2010/11/04/how-to-dual-boot-ubuntu-10-10-and-windows-7/"&gt;LinuxBSDos&lt;/a&gt; for a detailed explanation. If you face any problem let me know.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-1951686357486854128?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/1951686357486854128/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/setting-up-dual-boot-for-windows-7-and.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1951686357486854128'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1951686357486854128'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/setting-up-dual-boot-for-windows-7-and.html' title='Setting up Dual boot for Windows 7 and Ubuntu 10.10'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-1147726589383942954</id><published>2010-12-08T08:46:00.000-08:00</published><updated>2010-12-08T08:46:53.254-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Chrome OS from USB'/><category scheme='http://www.blogger.com/atom/ns#' term='Chrome OS'/><category scheme='http://www.blogger.com/atom/ns#' term='Chromium'/><title type='text'>Run Chrome OS on your Laptop from USB</title><content type='html'>&lt;div style="text-align: justify;"&gt;Recently I have run android on laptop, and it was meant for mobile. Google is dedicatedly developing a operating system for netbooks/notebooks. It is Chromium OS or Chrome OS. If most of the time you are spending on internet, and most used program on your PC is a browser, and you want to get online as early as possible from the time you pressed the power button then this is something you need to check it out.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;You need to have a spare USB stick, with minimum of 4GB space, and a laptop which can boot from USB. People have developed the image of Chrome OS for usb and uploaded in torrent, you can download it from the torrent.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 12px; line-height: 22px;"&gt;&lt;a href="http://www.makeuseof.com/downloads/chromium_os_usb.torrent" style="border-bottom-color: rgb(136, 136, 136); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(136, 136, 136); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(136, 136, 136); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(136, 136, 136); border-top-style: solid; border-top-width: 1px; color: #7c1212; font-weight: bold; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: none; outline-width: initial; padding-bottom: 4px; padding-left: 8px; padding-right: 8px; padding-top: 4px;"&gt;Download the Chromium OS for USB Torrent&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;There is small utility tool provided along with the image, it is called &lt;a href="https://launchpad.net/win32-image-writer"&gt;Windows Image Writer&lt;/a&gt;, its free and open source, used to write data into USB. What it does it it creates partitions in your usb disk, and then writes the data on the USB, so once written you will see that 3GB space is missing from your USB stick, dont get panic, you can restore it, refer to my blog about deleting oem partition, follow similar procedure, and with the help of windows disk management tool available in computer management section of control panel you will be able to recover it.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;It worked for me very well, infact the booting was not that fast, it might be little faster than the ubuntu version 8.04 which I was running, but then we can expect it to be faster once the full version is released. The best part is you can login with your gmail id, if connected to network, otherwise use chronos and password to login. You can see that wifi can be setup, it was working for me, browsing is same as on a chrome browser in linux, and nothing more, only browser in the whole operating system. Have fun trying it out !&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-1147726589383942954?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/1147726589383942954/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/run-chrome-os-on-your-laptop-from-usb.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1147726589383942954'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1147726589383942954'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/run-chrome-os-on-your-laptop-from-usb.html' title='Run Chrome OS on your Laptop from USB'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-4643382270303885483</id><published>2010-12-07T20:02:00.000-08:00</published><updated>2010-12-08T08:56:06.753-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Andorid-x86'/><category scheme='http://www.blogger.com/atom/ns#' term='Google Andorid'/><category scheme='http://www.blogger.com/atom/ns#' term='UNetbooin'/><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><title type='text'>How to install Android (x86) on Laptop</title><content type='html'>&lt;div style="text-align: justify;"&gt;Everyone is talking about android, the mobile OS from the internet giant Google. It is an open operating system for mobile phones, not meant for laptops. But already people have started porting the code to x86 machine and succeeded in booting laptops.&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Keeping in mind that, it is not a full&amp;nbsp;fledged&amp;nbsp;porting, depending on your laptop many things may work, and it may also turn out that it may not boot as well, so the call is yours, but nothing harm in trying out. Because the method I am going to explain you is using an USB thumb drive, so in case if it does not, just format the disk.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;You need to go to &lt;a href="http://www.android-x86.org/"&gt;Andorid x86 project&lt;/a&gt; website and download the &lt;a href="http://android-x86.googlecode.com/files/android-x86-1.6-r2.iso"&gt;latest stable release iso image&lt;/a&gt;. You need UNetBootin software to download this install this ISO image on your thumb drive, you can download it from &lt;a href="http://unetbootin.sourceforge.net/"&gt;here&lt;/a&gt;.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;You need to select the ISO option and give path to the .iso image you have downloaded, and make sure you select the correct device for USB, otherwise your data on hard disk will be wiped off. The example screen shot is as shown below.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://sourceforge.net/dbimage.php?id=173795" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em; text-align: justify;"&gt;&lt;img border="0" src="http://sourceforge.net/dbimage.php?id=173795" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Once the OK, is clicked, download will start, after the downloading to USB is complete, change the boot setting in BIOS to boot from USB and you are ready to boot Android x86, have fun. In my case, I was able to access my wifi router on my android, and it was fun browsing in Andorid. Unlike on virtual machine, the speed is really good on a laptop.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://3.bp.blogspot.com/_O-y4iQ3ddz4/TP-4KC71JlI/AAAAAAAAFWs/3twbAkJSUqg/s1600/Android_x86.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="298" src="http://3.bp.blogspot.com/_O-y4iQ3ddz4/TP-4KC71JlI/AAAAAAAAFWs/3twbAkJSUqg/s400/Android_x86.jpg" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;This is the screen shot of what I ran on my laptop, It's the mobile desktop scaled up. Still its a fun !&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-4643382270303885483?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/4643382270303885483/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/how-to-install-android-x86-on-laptop.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4643382270303885483'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4643382270303885483'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/12/how-to-install-android-x86-on-laptop.html' title='How to install Android (x86) on Laptop'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_O-y4iQ3ddz4/TP-4KC71JlI/AAAAAAAAFWs/3twbAkJSUqg/s72-c/Android_x86.jpg' height='72' width='72'/><thr:total>0</thr:total><georss:featurename>Bengaluru, Karnataka 560001, India</georss:featurename><georss:point>12.9715987 77.5945627</georss:point><georss:box>12.6370402 77.1276437 13.3061572 78.0614817</georss:box></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-1054910963404433639</id><published>2010-10-19T07:32:00.000-07:00</published><updated>2010-10-19T07:32:35.386-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows 7'/><category scheme='http://www.blogger.com/atom/ns#' term='recovery partition'/><category scheme='http://www.blogger.com/atom/ns#' term='Diskpart'/><title type='text'>How to delete OEM Recovery Partition</title><content type='html'>&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;I had Sony Vaio, installed with windows vista, and since these days the laptops dont come with the Operating system and device driver CD, they usually give a backup facility, for which they reserve a partion, and hence that space cannot be utilized.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Recently I have upgraded to Windows 7, and I dont need this partition anymore, so I wanted to remove the partition, I could have done it easily while installing windows 7, but once its installed, it cannot be directly removed from with the windows using the Computer Management program in windows. We need to used the command prompt version of Disk Partition utility.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Here is a guide to do the same, &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Open the Diskpart application by either typing in "Diskpart" (without the quotation marks) into the search, or type "Diskpart.exe" into Run by pressing the Windows key + R.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Now with Diskpart open, you must enter the following command lines:&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;Type "list disk" without the quotation marks and press enter.&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;Type in "select disk 0" and press enter.&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;Then type in "list partition" and press enter.&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;Then type in "select partition x" x=the recovery partition you wish to delete, replace x with the recovery partition number and press enter.&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;Then finally type in "delete partition override" and press enter.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div style="text-align: justify;"&gt;That should do the trick.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-1054910963404433639?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/1054910963404433639/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/10/how-to-delete-oem-recovery-partition.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1054910963404433639'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1054910963404433639'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/10/how-to-delete-oem-recovery-partition.html' title='How to delete OEM Recovery Partition'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-2429004501187431694</id><published>2010-10-18T10:16:00.000-07:00</published><updated>2010-10-18T20:49:48.734-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Function Keys'/><category scheme='http://www.blogger.com/atom/ns#' term='Sony Vaio'/><category scheme='http://www.blogger.com/atom/ns#' term='Web Cam'/><category scheme='http://www.blogger.com/atom/ns#' term='SD Card Reader'/><category scheme='http://www.blogger.com/atom/ns#' term='Graphics'/><category scheme='http://www.blogger.com/atom/ns#' term='Wirless LAN Switch'/><category scheme='http://www.blogger.com/atom/ns#' term='CR313H'/><category scheme='http://www.blogger.com/atom/ns#' term='Switch Utility'/><category scheme='http://www.blogger.com/atom/ns#' term='Brightness Keys'/><title type='text'>Windows 7, With All Drivers on Sony VAIO CR313H</title><content type='html'>&lt;div style="text-align: justify;"&gt;Recently I have upgraded from the so called the slower version of windows (Windows Vista) to windows 7, the latest and the faster one. Everything looked nice, until I realize that my webcam is not working when I try to use Google talk on Gmail for video call. I was bit worried, thought it is not so difficult to fix it, as I knew camera driver is missing, and I did some google-ing and found that it’s not so easy to get your camera working on the laptop, mostly because it is a 2 year old laptop and Sony Vaio’s official site does not give any drivers and nowhere else also the exact drivers are available. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Now I did worry a bit more, but without losing hope I did some more research on the internet and found that there is driver for the web camera which many people have claimed to work on VAIO laptops. I did give a try, and amazing! It’s working!! Here is a &lt;a href="http://download.cnet.com/Sony-Visual-Communication-Camera-VGP-VCC6/3000-2110_4-172885.html"&gt;link&lt;/a&gt; to download the same if you are having similar problems. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;I was wondering, if other things on my laptops are working fine, I found that the display and the graphics drivers are missing, and Bluetooth and WLAN switch setting is missing, SD Card Reader is not working, None of the function keys are working, especially the brightness control keys, and Fn+F7 (Dual Mode + Monitor Extension). This is now a serious problem, I thought I must fix this. I called up one of my friend who works for Sony; he was on his way back to native for his sister’s engagement, so wasn’t so useful.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;I did more search on the internet to find the display driver for my Intel graphics accelerator x3100, and after installing that the graphics did flicker few times, but worked wonders and I could see all the options I was able to see when Vista was there, I was happy, this was the first success. Here is a &lt;a href="http://www.downloadatoz.com/driver/item_intel-graphics-media-accelerator-driver-15-12-75-4-1930-for-win7.html"&gt;link&lt;/a&gt; if you want to download the same driver for your CR313H laptop, or with the same Intel graphics accelerator. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Later for the others, I started searching to make function keys working, and while searching, I found a forum on windows 7, where things which are solved are marked as SOLVED, which helped find the thread easily, and I found memory card driver, you can download it &lt;a href="http://www.sevenforums.com/attachments/drivers/48838d1263991975-memory-card-reader-sony-vaio-vgn-fz350ae-memory-card.zip"&gt;here&lt;/a&gt;. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;I also got a thread, where someone had installed all the utilities needed for the functions keys to work properly. You have to download and Install the following Utilities from the SONY VAIO ftp link ftp://ftp.vaio-link.com/PUB/VAIO/ORIGINAL/ . And Note that all the below needs to be installed in the same order for it to work properly. Download the LATEST version available for each of them and install.&lt;/div&gt;&lt;ol&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;Sony Firmware Extension Parser (SFEP) Driver&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;Sony Shared Library&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;Setting Utility Series&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;Vaio Control Center (if you want it)&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;Vaio event service&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;div style="text-align: justify;"&gt;This makes all the features on my SONY VAIO laptop work. If you have any problems, feel free to write to me.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-2429004501187431694?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/2429004501187431694/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/10/windows-7-with-all-drivers-on-sony-vaio.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2429004501187431694'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2429004501187431694'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/10/windows-7-with-all-drivers-on-sony-vaio.html' title='Windows 7, With All Drivers on Sony VAIO CR313H'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-7168054136501083325</id><published>2010-09-20T01:59:00.000-07:00</published><updated>2010-09-20T01:59:38.302-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='data structures'/><category scheme='http://www.blogger.com/atom/ns#' term='linked list'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>Single Linked List Example - Add/Delete</title><content type='html'>Here is the sample program, I have written to explain the singly linked list. This has three functions, one to insert to the list at the head, which is pretty easy by making the new item as the head, and other one to remove from the list when the data is found, 3rd one to insert to the tail of the list, in this case you need to traverse till the end of the list and then insert the item there.&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;#include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include &amp;lt;malloc.h&amp;gt;&lt;br /&gt;&lt;br /&gt;typedef struct node_type {&lt;br /&gt;    int data;&lt;br /&gt;    struct node_type *next;&lt;br /&gt;} node;&lt;br /&gt;&lt;br /&gt;node *list_head = NULL;&lt;br /&gt;&lt;br /&gt;void insert_list(node **plist_head, int data)&lt;br /&gt;{&lt;br /&gt;    node *item = (node *)malloc(sizeof(node));&lt;br /&gt;    item-&amp;gt;data = data;&lt;br /&gt;    item-&amp;gt;next = *plist_head;&lt;br /&gt;    *plist_head = item;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;void insert_list_tail(node **plist_head, int data)&lt;br /&gt;{&lt;br /&gt;    node **list_ptr = plist_head;&lt;br /&gt;    node *item = (node *)malloc(sizeof(node));&lt;br /&gt;    item-&amp;gt;data = data;&lt;br /&gt;    item-&amp;gt;next = NULL;&lt;br /&gt;&lt;br /&gt;    while(*list_ptr) &lt;br /&gt;        list_ptr = &amp;amp;(*list_ptr)-&amp;gt;next;&lt;br /&gt;&lt;br /&gt;    *list_ptr = item;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;void show_list(node **list_head)&lt;br /&gt;{&lt;br /&gt;    node **list_ptr = list_head;&lt;br /&gt;    while(*list_ptr)&lt;br /&gt;    {    &lt;br /&gt;        printf("%d\t", (*list_ptr)-&amp;gt;data);&lt;br /&gt;        list_ptr = &amp;amp;(*list_ptr)-&amp;gt;next;&lt;br /&gt;    } &lt;br /&gt;    printf("\n");&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;void remove_list(node **plist_head, int data)&lt;br /&gt;{&lt;br /&gt;    node **list_ptr = plist_head;&lt;br /&gt;    while(*list_ptr)&lt;br /&gt;    {&lt;br /&gt;        if((*list_ptr)-&amp;gt;data == data)&lt;br /&gt;        {&lt;br /&gt;            node *tmp = *list_ptr;&lt;br /&gt;            *list_ptr = (*list_ptr)-&amp;gt;next;&lt;br /&gt;            free(tmp);&lt;br /&gt;            break;&lt;br /&gt;        }&lt;br /&gt;        list_ptr = &amp;amp;(*list_ptr)-&amp;gt;next;&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;main()&lt;br /&gt;{&lt;br /&gt;    show_list(&amp;amp;list_head);&lt;br /&gt;    insert_list(&amp;amp;list_head, 2);&lt;br /&gt;    show_list(&amp;amp;list_head);&lt;br /&gt;    insert_list(&amp;amp;list_head, 5);&lt;br /&gt;    show_list(&amp;amp;list_head);&lt;br /&gt;    insert_list(&amp;amp;list_head, 9);&lt;br /&gt;    show_list(&amp;amp;list_head);&lt;br /&gt;    insert_list(&amp;amp;list_head, 1);&lt;br /&gt;    show_list(&amp;amp;list_head);&lt;br /&gt;    remove_list(&amp;amp;list_head, 9);&lt;br /&gt;    show_list(&amp;amp;list_head);&lt;br /&gt;    remove_list(&amp;amp;list_head, 2);&lt;br /&gt;    show_list(&amp;amp;list_head);&lt;br /&gt;    insert_list_tail(&amp;amp;list_head, 8);&lt;br /&gt;    insert_list_tail(&amp;amp;list_head, 12);&lt;br /&gt;    show_list(&amp;amp;list_head);&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;Hope this will help someone who just has just started learning Linked list in C, let me know if something is not clear.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-7168054136501083325?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/7168054136501083325/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/09/single-linked-list-example-adddelete.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7168054136501083325'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7168054136501083325'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/09/single-linked-list-example-adddelete.html' title='Single Linked List Example - Add/Delete'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-8505145046548840617</id><published>2010-09-16T09:56:00.000-07:00</published><updated>2010-09-16T09:56:22.443-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>Where is ZERO size array is used?</title><content type='html'>If you normally try to declare a zero size array, you would end of getting array, but if the same is used as the last element of a structure then it does not give any error. Infact its method or trick to use variable size array for the last element, this can be achived as shown in the below program.&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;#include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include &amp;lt;malloc.h&amp;gt;&lt;br /&gt;#include &amp;lt;string.h&amp;gt;&lt;br /&gt;&lt;br /&gt;typedef struct &lt;br /&gt;{&lt;br /&gt;    int d;&lt;br /&gt;    char name[0];&lt;br /&gt;}s;&lt;br /&gt;&lt;br /&gt;int main(void)&lt;br /&gt;{&lt;br /&gt;    char str[] = "prasad";&lt;br /&gt;    int len;&lt;br /&gt;    s *s1;&lt;br /&gt;    len = strlen(str);&lt;br /&gt;    s1 = (s *)malloc(sizeof(*s1) + len + 1);&lt;br /&gt;    strcpy(s1-&amp;gt;name, str);&lt;br /&gt;    s1-&amp;gt;d = 12345678;&lt;br /&gt;    printf("d : %d  name : %s", s1-&amp;gt;d, s1-&amp;gt;name);&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;This kind of trick is normally not required, and you can program most of the things in this world with out using this, but still some people want to show that they can do something special than everybody, so they can do this trick, but when you do this you must be extra careful as you need to allocate right amount of memory for the variable size array, else you would end of corrupting others memory.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-8505145046548840617?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/8505145046548840617/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/09/where-is-zero-size-array-is-used.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8505145046548840617'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8505145046548840617'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/09/where-is-zero-size-array-is-used.html' title='Where is ZERO size array is used?'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-7847244704796617832</id><published>2010-09-14T06:20:00.000-07:00</published><updated>2010-09-16T09:51:40.803-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='MSVC'/><category scheme='http://www.blogger.com/atom/ns#' term='Visual Studio'/><category scheme='http://www.blogger.com/atom/ns#' term='SDL'/><title type='text'>How to setup SDL-Library for Visual Studio Compiler</title><content type='html'>&lt;ol&gt;&lt;li&gt;On the &lt;a href="http://www.libsdl.org/"&gt;SDL&lt;/a&gt; download page, get the latest version of the Windows-VC development libraries. &lt;/li&gt;&lt;li&gt;If you want to use the SDL_mixer library (for sound and music), download the Windows-VC development libraries for SDL_mixer. &lt;/li&gt;&lt;li&gt;Uncompress the SDL and SDL_mixer libraries to your local drive. &lt;/li&gt;&lt;li&gt;Consolidate the SDL includes and libraries with the SDL_mixer includes and libraries, so that they're all in a single set of \include and \lib folders. It's easier this way! &lt;/li&gt;&lt;li&gt;Launch Visual Studio .NET, but do not open a project or solution. &lt;/li&gt;&lt;li&gt;From the Tools menu, select Options... &lt;/li&gt;&lt;li&gt;In the tree view, click on Projects and then select VC++ Directories. &lt;/li&gt;&lt;li&gt;In the Show directories for box, select Include files. &lt;/li&gt;&lt;li&gt;Click the new-folder icon, and browse to the \include directory where you consolidated your SDL and SDL_mixer header files. &lt;/li&gt;&lt;li&gt;In the Show directories for box, you now need to select Library files. &lt;/li&gt;&lt;li&gt;Click the new-folder icon, and browse to the \lib directory where you consolidated your SDL and SDL_mixer library files. &lt;/li&gt;&lt;li&gt;Click OK. &lt;/li&gt;&lt;/ol&gt;&lt;div&gt;Your build environment is now set up, and VC++.NET will now know where to find the SDL and SDL_mixer headers and libraries. To create an SDL project, perform the following steps. &lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;ol&gt;&lt;li&gt;Launch Visual Studio .NET and from the File menu, select New and then Project... &lt;/li&gt;&lt;li&gt;In the tree view, expand Visual C++ Projects and select Win32. &lt;/li&gt;&lt;li&gt;If you don't want a console window to appear when your program is executed, select Win32 Project. Otherwise, select Win32 Console Project. Give your project a name and location, then click OK. &lt;/li&gt;&lt;li&gt;From the Project menu, select Properties... at the bottom of the menu. &lt;/li&gt;&lt;li&gt;In the tree view, expand C/C++ and select Code Generation. &lt;/li&gt;&lt;li&gt;Set the Runtime Library value to Multi-threaded DLL or Multi-threaded Debug DLL. &lt;/li&gt;&lt;li&gt;We're still in the Properties dialog. In the tree view, now expand Linker and select Command Line. &lt;/li&gt;&lt;li&gt;In the Additional Options field, enter SDL.lib SDLmain.lib and if you are using SDL_mixer, also add SDL_mixer.lib. &lt;/li&gt;&lt;li&gt;VC++ is now set up. You may add your SDL source code to the project, and proceed as normal. &lt;/li&gt;&lt;/ol&gt;&lt;strong&gt;NOTES:&lt;/strong&gt; &lt;br /&gt;&lt;ul&gt;&lt;li&gt;The SDL Windows FAQ states that this step is necessary because, "SDL is dynamically linked with the multi-threaded version of the Microsoft Visual C runtime." &lt;/li&gt;&lt;li&gt;If you plan on running the VC++ debugger with SDL you will have to pass the value SDL_INIT_NOPARACHUTE to SDL_Init in order for debugging to succeed! &lt;/li&gt;&lt;li&gt;When you compile your executable, you will need to copy the SDL.dll and SDL_mixer.dll files into the same folder as the EXE. If these DLLs are missing, when the program is executed you will be given an error message regarding the needed DLLs. &lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-7847244704796617832?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/7847244704796617832/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/09/how-to-setup-sdl-library-for-visual.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7847244704796617832'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7847244704796617832'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/09/how-to-setup-sdl-library-for-visual.html' title='How to setup SDL-Library for Visual Studio Compiler'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-5902152606765747654</id><published>2010-09-13T03:27:00.000-07:00</published><updated>2010-09-13T03:27:43.295-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='pointers'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><category scheme='http://www.blogger.com/atom/ns#' term='arrays'/><title type='text'>How to use Pointers for 2D Arrays</title><content type='html'>This is when, you want to have a two dimentional array and whos column size of fixed, but how many number of rows you need, you want to decide run time, in that case you may want to allocate memory for the whole 2D array dynamically. But the access to that array should be as simple as accessing it normally when declared using the standard syntax, i.e by using row and column numbers.&lt;br /&gt;&lt;br /&gt;Remember that you cannot use, int **p for this purpose, or even int *p[4] for this purpose.&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;#include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include &amp;lt;malloc.h&amp;gt;&lt;br /&gt;&lt;br /&gt;main()&lt;br /&gt;{&lt;br /&gt;    int i, j;&lt;br /&gt;    int a[3][4];&lt;br /&gt;    int (*p)[4];&lt;br /&gt;&lt;br /&gt;    int size = 3;&lt;br /&gt;    p = (int (*)[4])malloc(12*4);&lt;br /&gt;    for(i=0; i&amp;lt;3; i++)&lt;br /&gt;        for(j=0; j&amp;lt;4; j++)&lt;br /&gt;        {&lt;br /&gt;            p[i][j] = i+j;&lt;br /&gt;            a[i][j] = p[i][j];&lt;br /&gt;        }&lt;br /&gt;&lt;br /&gt;    for(i=0; i&amp;lt;3; i++)&lt;br /&gt;    {&lt;br /&gt;        for(j=0; j&amp;lt;4; j++)&lt;br /&gt;            printf("%d ", a[i][j]);&lt;br /&gt;        printf("\n");&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;Have a nice time, and enjoy programming.!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-5902152606765747654?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/5902152606765747654/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/09/how-to-use-pointers-for-2d-arrays.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5902152606765747654'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5902152606765747654'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/09/how-to-use-pointers-for-2d-arrays.html' title='How to use Pointers for 2D Arrays'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-1271760676688354280</id><published>2010-08-28T03:46:00.000-07:00</published><updated>2010-08-28T03:46:25.464-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='c++'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><title type='text'>An Overview of C++</title><content type='html'>&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;1) What is a structured language?&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;The languages such as C and PASCAL are structure languages, which are characterized by their support for stand-alone subroutines, local variables, rich control constructs and their lack of reliance upon the GOTO statements.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;2) What is the basic difference between the object oriented programming language and the structured pro-gramming language?&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;In structured programming language, the program is organized around the code, means, program is struc-tures into subroutines or functions which act on data, on the other hand the object oriented programming you define the data type, which will define how can access that data, in the sense the program is organized around data.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;3) What are the characteristics of C++ or object oriented programming language?&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;The three main characteristics of an object oriented programming language is Encapsulation, Polymorphism and Inheritance. The class definitions explains encapsulation, the function and operator overloading explains polymorphism and the &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;4) What is Encapsulation in Object oriented programming language?&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Encapsulation is a mechanism that binds together the code and the data it manipulates, and keep both safe from outside interference and misuse, the private data or code is accessible only within that object or class and public data or code can be accessed from outside, which gives an interface to the outside world to access the inside code and data of object.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;5) What is polymorphism and what kind of polymorphisms are supported in C++?&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;One interface, multiple methods, in simple terms it is an attribute that allows one interface to control access to a general class of actions, the specific action selected is determined by the exact nature of the situation. Compiler will select the method appropriate for a particular situation, and programmers don’t need do it manually. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;C++ supports both run time and compile time polymorphism. Compile time using function overloading and operator overloading. Run time using virtual functions.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;6) What is inheritance in object oriented programming languages?&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;This is a concept of classification, where an objects property can be derived from another object, and it only needs to define those qualities that make it unique within its class. Example the Apple belongs to the class fruits and fruits belongs to class food etc.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;7) How does bool data type is defined in C++?&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;There is standard Boolean data type in C++, which takes value true or false, true being 1 and false being zero automatic conversion to integer is supported, all non-zero value is treated as true and zero as false. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;8) What is a class in C++&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Class is a means to define an objects outline using data and code and access permissions, this is the inheri-tance is achieved in C++.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;9) What is function overloading?&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;When you have similar tasks to be performed then you can declare functions with same name, keeping the number of parameters and /or their type different. Then the compiler will select the right function depending on the situation. This process is called function overloading. It is not only enough to keep the return type different. This is a polymorphism feature of C++. The other polymorphism feature available in C++ is operator overloading. There is run time polymorphism also using virtual functions using inheritance and derived class.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;10) What are constructor and destructors?&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;It is very often that we need to initialize the class before we can use them, so C++ provides a way to auto-matically do it using constructor and then de-allocate any resources in the destructor. The constructor has same name as that of the class and it does not have any return type, because constructor cannot return anything. It should also be public member function of the class, because objects of that class needs to be defined in public scope. The same rules apply to the destructors also, destructors names has additional ~ at the beginning. The constructors are called when the declaration statements are executed, and destructors are called when the objects are destroyed&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-1271760676688354280?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/1271760676688354280/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/overview-of-c.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1271760676688354280'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1271760676688354280'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/overview-of-c.html' title='An Overview of C++'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-3662893691461295392</id><published>2010-08-11T10:43:00.000-07:00</published><updated>2010-08-11T10:43:27.538-07:00</updated><title type='text'>Dynamic Memory Management</title><content type='html'>&lt;strong&gt;1) What are the approaches for dynamic memory management?&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Explicit:&lt;/strong&gt; Explicit memory allocation and de-allocation using malloc() and free() by the programmer, this can be very efficient, but its error prone, when a programmer forgets to free the allocated memory.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Automatic:&lt;/strong&gt; In this approach the programmer allocates the memory but the run time system takes care of claiming the un-used memory (garbage collection). This kind of method is used in languages such as Java, this can be very simple for the programmer but it can lead to slow performance, since run time system needs to decide which memory to be reclaimed. &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;2) How does malloc work?&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;Before calling main(), C runtime system asks OS for large chunk of memory. This will serve as the heap for that program. Malloc() carves out a piece of the heap records the fact that it is allocated, so subsequent calls to malloc will not use this storage. When free() is called, records the fact that piece of heap is no longer allocated, subsequent calls to malloc can use it.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;3) How does malloc manage the Heap?&lt;/strong&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Free data is arranged in a linked list (free list)&lt;/li&gt;&lt;li&gt;Next pointer embedded in free data itself (rather than building a separate “list” structure as shown in figure&lt;/li&gt;&lt;li&gt;Each chunk is “tagged” with size (prefix or auxiliary table)&lt;/li&gt;&lt;li style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"&gt;When malloc called, &lt;/li&gt;&lt;li style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"&gt;Scan list for sufficiently large chunk, Chunk may need to be split&lt;/li&gt;&lt;li style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"&gt;Returned chunk also “tagged” with size&lt;/li&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/_O-y4iQ3ddz4/TGLedNPS_DI/AAAAAAAAFFU/QTkVkw0_N-M/s1600/malloc.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="190" ox="true" src="http://2.bp.blogspot.com/_O-y4iQ3ddz4/TGLedNPS_DI/AAAAAAAAFFU/QTkVkw0_N-M/s400/malloc.jpg" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;li style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"&gt;When Free is called,&lt;/li&gt;&lt;li style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"&gt;Adds chunk of data back onto the free list (at head)&lt;/li&gt;&lt;li style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"&gt;Size available in “tag” &lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;div style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none;"&gt;&lt;/div&gt;&lt;div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/_O-y4iQ3ddz4/TGLfT4A9S2I/AAAAAAAAFFY/BlJjU1yIu3U/s1600/free.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="221" ox="true" src="http://2.bp.blogspot.com/_O-y4iQ3ddz4/TGLfT4A9S2I/AAAAAAAAFFY/BlJjU1yIu3U/s400/free.jpg" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class="separator" style="border-bottom: medium none; border-left: medium none; border-right: medium none; border-top: medium none; clear: both; text-align: left;"&gt;&lt;/div&gt;&lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;strong&gt;4) What are the problems associated with Malloc() and Free()&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;a. What if wrong address is freed?&lt;br /&gt;- Consider the following code example,&lt;br /&gt;&lt;blockquote&gt;p = malloc(x);&lt;br /&gt;p++;&lt;br /&gt;free(p);&lt;/blockquote&gt;In this case the size info will be wrong!, and hence the program will likely (later) fail in mysterious ways&lt;br /&gt;&lt;br /&gt;b. What if same chunk is freed twice?&lt;br /&gt;- Often results in free-list cycle&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;5) More Problems&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;a) Fragmentation&lt;/strong&gt;&lt;br /&gt;&amp;nbsp;• After a while, we end up with lots of small chunks&lt;br /&gt;&amp;nbsp;• May have enough memory for some request, but not contiguous&lt;br /&gt;&amp;nbsp;• Solutions&lt;br /&gt;&lt;blockquote&gt;1) Allow heap to grow (ask OS for more memory)&lt;br /&gt;2) Choose chunks wisely: best fit v. first fit&lt;/blockquote&gt;&lt;strong&gt;b) Slow allocation&lt;/strong&gt;&lt;br /&gt;&amp;nbsp;• Must traverse long list to find suitable chunk of memory&lt;br /&gt;&amp;nbsp;• Solutions&lt;br /&gt;&lt;blockquote&gt;1) Sort free list (now free is slower)&lt;br /&gt;2) Multiple free lists (e.g., one for large chunks, one for small, etc.)&lt;/blockquote&gt;&lt;strong&gt;c) Bugs&lt;/strong&gt;&lt;br /&gt;&amp;nbsp;• Wild writes can corrupt size or next pointers&lt;br /&gt;&amp;nbsp;• Solution?&lt;br /&gt;&lt;blockquote&gt;1) Use auxiliary structure to record size (doesn’t actually solve problem)&lt;br /&gt;2) Valgrind (provides its own implementation of malloc)&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-3662893691461295392?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/3662893691461295392/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/dynamic-memory-management.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3662893691461295392'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3662893691461295392'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/dynamic-memory-management.html' title='Dynamic Memory Management'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_O-y4iQ3ddz4/TGLedNPS_DI/AAAAAAAAFFU/QTkVkw0_N-M/s72-c/malloc.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-2325404395674306055</id><published>2010-08-11T10:07:00.000-07:00</published><updated>2010-08-11T10:07:42.886-07:00</updated><title type='text'>Initrd and initramfs</title><content type='html'>&lt;strong&gt;Initrd Creation&lt;/strong&gt; &lt;br /&gt;&lt;br /&gt;To create an (initially empty) initrd use the following steps: &lt;br /&gt;Note: Change count to your required filesystem size. E.g. with count=8192 you will get a 8MB ramdisk. &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; dd if=/dev/zero of=/dev/ram0 bs=1k count=&amp;lt;count&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; mke2fs -vm0 /dev/ram0 &amp;lt;count&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; tune2fs -c 0 /dev/ram0&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; dd if=/dev/ram0 bs=1k count=&amp;lt;count&amp;gt;&amp;nbsp; | gzip -v9 &amp;gt; ramdisk.gz&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Now, we have a (empty) gzipped ramdisk image with (extracted) size of &amp;lt;count&amp;gt;. &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Filling&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;To fill empty ramdisk created above with all files needed for ramdisk, mount the image and fill it. Content would be e.g. BusyBox and/or other applications and/or libraries. &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; mkdir mnt&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; gunzip ramdisk.gz&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; mount -o loop ramdisk mnt/&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; ... copy stuff you want to have in ramdisk to mnt...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; umount mnt&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; gzip -v9 ramdisk&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The resulting ramdisk.gz is now ready for usage. Note its size is smaller than &amp;lt;count&amp;gt; cause of compression. &lt;br /&gt;&lt;br /&gt;Note: Don't forget to create/copy some basic /dev/xxx nodes to ramdisk. &lt;br /&gt;&lt;br /&gt;Note: If BusyBox or applications in ramdisk are linked dynamically, don't forget to copy dynamic libraries (*.so) to ramdisk (to correct directory) as well. &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Kernel options&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;To make initrd work, you have to configure kernel properly: &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;#&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;# General setup&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;#&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_BLK_DEV_INITRD=y&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_INITRAMFS_SOURCE=""&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;#&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;# UBI - Unsorted block images&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;#&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_BLK_DEV_RAM=y&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_BLK_DEV_RAM_COUNT=1&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_BLK_DEV_RAM_SIZE=8192&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;Note: The ramdisk size e.g. 8192 above has to be configured for your individual setup. &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Installation&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;Now, you can install the ramdisk via u-boot e.g. in NOR flash. For this copy filled ramdisk created above to your tftpboot directory on host (e.g. /tftpboot/ramdisk.gz). Then start target and copy the data into RAM and flash: &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;UBOOT # tftp 0x87000000 ramdisk.gz&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;UBOOT # erase 0x2200000 +0x&amp;lt;filesize&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;UBOOT # cp.b 0x87000000 0x2200000 0x&amp;lt;filesize&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Note: Replace filesize above by the value the tftp download command gives you as Bytes transferred. &lt;br /&gt;Now, last step is to update kernel boot parameters and save them &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;UBOOT # setenv bootargs ... root=/dev/ram0 rw initrd=0x87000000,8M&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;UBOOT # setenv bootcmd cp.b 0x2200000 0x87000000 0x&amp;lt;filesize&amp;gt;; bootm&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;UBOOT # saveenv&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Note: In example above with "8M" we assume that your ramdisk is 8MBytes. Adapt this to your needs. &lt;br /&gt;Note: Your ramdisk filled above should have a /dev/ram0 node to make this work properly.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;brw-rw---- 1 root disk 1, 0 Sep 11 1999 /dev/ram0&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Now you should be able to start your kernel and it should find and mount the initrd: &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;Linux version 2.6.23-davinci1 ...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;checking if image is initramfs...it isn't (no cpio magic); looks like an initrd&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;Freeing initrd memory: 8192K&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;RAMDISK driver initialized: 1 RAM disks of 8192K size 1024 blocksize&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;RAMDISK: Compressed image found at block 0&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;VFS: Mounted root (ext2 filesystem).&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;Freeing init memory: ...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Initramfs&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;To use initramfs a cpio archive is embedded directly into the kernel. I.e. you don't create an additional (ramdisk) image. Instead, the initial file system is directly incorporated into the kernel. With this, the kernel size increases by the file system size. It's like you embed above ramdisk directly into the kernel. &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Creation&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;Cause initramfs is directly embedded in the the kernel, its creation is simpler. No dd &amp;amp; mount &amp;amp; gzip stuff like with ramdisk above. You simply have to fill a directory on your host with the target filesystem you like and then pass the path to this directory to the kernel build process. &lt;br /&gt;&lt;br /&gt;Create target file system &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; mkdir target_fs&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;host &amp;gt; ... copy stuff you want to have in initramfs to target_fs...&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Note: cpio system used for initramfs can't handle hard links. If you e.g. created your BusyBox using hard links, you will get a quite large initramfs cause each command is taken with its size and not as hard link. In cpio initramfs use symbolic/soft links instead. &lt;br /&gt;&lt;br /&gt;Note: To be able to detect initramfs by kernel properly, the top level directory has to contain a program called init. This can be done by e.g. using a soft link from top level init to /bin/busybox &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;/init -&amp;gt; /bin/busybox&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;if you use BusyBox in your initramfs. &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Kernel options&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;The only difference from creating an initrd is to give the kernel the path to the target file system you like to embed: &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;#&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;# General setup&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;#&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_BLK_DEV_INITRD=y&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_INITRAMFS_SOURCE="&amp;lt;path_to&amp;gt;/target_fs&amp;gt;"&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;#&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;# UBI - Unsorted block images&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;#&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_BLK_DEV_RAM=y&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_BLK_DEV_RAM_COUNT=1&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_BLK_DEV_RAM_SIZE=8192&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Then, if you compile the kernel, e.g. by make uImage, the cpio archive is generated and embedded into the kernel: &lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;CHK include/linux/compile.h&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;GEN usr/initramfs_data.cpio.gz&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;AS usr/initramfs_data.o&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;LD usr/built-in.o&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;...&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Installation&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;No special installation like above with initrd is necessary. The initramfs is already in the kernel. If you start the kernel, the initramfs is already there. Therefore, there is no root=/dev/ram0 rw initrd=0x87000000,8M bootargs option necessary. Remove this if you still have it! &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;initrd vs. initramfs&lt;/strong&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Using initrd, kernel and initial file system are splitted. Making changes to kernel or filesystem doesn't touch the other one. The download size (e.g. while development) of one component is smaller. &lt;/li&gt;&lt;li&gt;Creating and modifying an initramfs is easier than with initrd (unzip &amp;amp; mount &amp;amp; unmount &amp;amp; zip) &lt;/li&gt;&lt;li&gt;Having one big image (kernel &amp;amp; initramfs) is easier to handle (e.g. download or flashing) than having two splitted images. &lt;/li&gt;&lt;/ol&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-2325404395674306055?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/2325404395674306055/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/initrd-and-initramfs.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2325404395674306055'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2325404395674306055'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/initrd-and-initramfs.html' title='Initrd and initramfs'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-552367572601381345</id><published>2010-08-10T07:18:00.000-07:00</published><updated>2010-08-10T07:18:08.990-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='c++'/><category scheme='http://www.blogger.com/atom/ns#' term='mixed language'/><category scheme='http://www.blogger.com/atom/ns#' term='compiler'/><category scheme='http://www.blogger.com/atom/ns#' term='extern'/><category scheme='http://www.blogger.com/atom/ns#' term='mangling'/><category scheme='http://www.blogger.com/atom/ns#' term='linkage'/><title type='text'>Mixed-Language Programming and External Linkage</title><content type='html'>&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;The C++ standard provides a mechanism called linkage specification for mixing code that was written in different programming languages and was compiled by the respective compilers, in the same program. Linkage specification refers to the protocol for linking functions or procedures written in different languages. Linkage is the term used by the C++ standard to describe the accessibility of objects from one file to another or even within the same file. Three types of linkage exist: &lt;/div&gt;&lt;ol&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;No linkage&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;Internal linkage&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div style="text-align: justify;"&gt;External linkage&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;div style="text-align: justify;"&gt;Something internal to a function, in regard to its arguments, variables, and so on, always has no linkage and hence can be accessed only within the function. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Sometimes it is necessary to declare functions and other objects within a single file in a way that allows them to reference each other, but not to be accessible from outside that file. This can be done through internal linkage. Symbols with internal linkage only refer to the same object within a single source file. Prefixing the declarations with the keyword static changes the linkage of external objects from external linkage to internal linkage. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Objects that have external linkage are all considered to be located at the outermost level of the program. This is the default linkage for functions and anything declared outside of a function. All instances of a particular name with external linkage refer to the same object in the program. If two or more declarations of the same symbol have external linkage, but with incompatible types (for example, mismatch of declaration and definition), then the program may either crash or show abnormal behaviour. The rest of the article discusses one of the issues with mixed code and provides a recommended solution with external linkage.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;In the real world, it is very common to use the functionality of code written in one programming language from code written in another. A trivial example is a C++ programmer relying on a standard C library (libc) for sorting a series of integers with the "quick sort" technique. It works because the C implementation takes care of the language linkage for us. But we need to take additional care if we use our own libraries written in C, from a C++ program. Otherwise the compilation may fail with link errors caused by unresolved symbols. Consider the following example: &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Assume that we're writing C++ code and wish to call a C function from C++ code. Here's the code for the callee, for example, C routine:&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;%cat greet.h&lt;br /&gt;extern char *greet();&lt;br /&gt;&lt;br /&gt;%cat greet.c&lt;br /&gt;#include "greet.h"&lt;br /&gt;&lt;br /&gt;char *greet() {&lt;br /&gt;           return ((char *) "Hello!");&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;%cc -G -o libgreet.so greet.c&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Note: The extern keyword declares a variable or function and specifies that it has external linkage, i.e., its name is visible from files other than the one in which it's defined. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;Let's try to call the C function greet() from a C++ program &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;%cat mixedcode.cpp&lt;br /&gt;#include &amp;lt;iostream.h&amp;gt;&lt;br /&gt;#include "greet.h"&lt;br /&gt;&lt;br /&gt;int main() {&lt;br /&gt;        char *greeting = greet();&lt;br /&gt;    cout &amp;lt;&amp;lt; greeting &amp;lt;&amp;lt; "\n";&lt;br /&gt;        return (0);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt; &lt;br /&gt;%CC -lgreet mixedcode.cpp&lt;br /&gt;Undefined                       first referenced&lt;br /&gt; symbol                            in file&lt;br /&gt;char*greet()                    mixedcode.o&lt;br /&gt;ld: fatal: Symbol referencing errors. No output written to a.out&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Though the C++ code is linked with the dynamic library that holds the implementation for greet(), libgreet.so, the linking failed with undefined symbol error. What went wrong?&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;The reason for the link error is that a typical C++ compiler mangles (encodes) function names to support function overloading. So, the symbol greet is changed to something else depending on the algorithm implemented in the compiler during the name mangling process. Hence the object file does not have the symbol greet anywhere in the symbol table. The symbol table of mixedcode.o confirms this. Let's have a look at the symbol tables of both libgreet.so and mixedcode.o: &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;%elfdump1 -s libgreet.so&lt;br /&gt;&lt;br /&gt;Symbol Table Section:  .symtab&lt;br /&gt;index    value       size     type bind oth ver shndx       name&lt;br /&gt;...&lt;br /&gt;[1]  0x00000000 0x00000000  FILE LOCL  D    0 ABS         libgreet.so&lt;br /&gt;...&lt;br /&gt;[37]  0x00000268 0x00000004  OBJT GLOB  D    0 .rodata     _lib_version&lt;br /&gt;[38]  0x000102f3 0x00000000  OBJT GLOB  D    0 .data1      _edata&lt;br /&gt;[39]  0x00000228 0x00000028  FUNC GLOB  D    0 .text       greet&lt;br /&gt;[40]  0x0001026c 0x00000000  OBJT GLOB  D    0 .dynamic    _DYNAMIC&lt;br /&gt;&lt;br /&gt;%elfdump -s mixedcode.o&lt;br /&gt;&lt;br /&gt;Symbol Table Section:  .symtab&lt;br /&gt;index    value       size     type bind oth ver shndx       name&lt;br /&gt;[0]  0x00000000 0x00000000  NOTY LOCL  D    0 UNDEF&lt;br /&gt;[1]  0x00000000 0x00000000  FILE LOCL  D    0 ABS         mixedcode.cpp&lt;br /&gt;[2]  0x00000000 0x00000000  SECT LOCL  D    0 .rodata&lt;br /&gt;[3]  0x00000000 0x00000000  FUNC GLOB  D    0 UNDEF     &lt;br /&gt;    __1cDstd2l6Frn0ANbasic_ostream4Ccn0ALchar_traits4Cc____pkc_2_&lt;br /&gt;[4]  0x00000000 0x00000000  FUNC GLOB  D    0 UNDEF       __1cFgreet6F_pc_&lt;br /&gt;[5]  0x00000000 0x00000000  NOTY GLOB  D    0 UNDEF       __1cDstdEcout_&lt;br /&gt;[6]  0x00000010 0x00000050  FUNC GLOB  D    0 .text       main&lt;br /&gt;[7]  0x00000000 0x00000000  NOTY GLOB  D    0 ABS         __fsr_init_value&lt;br /&gt;&lt;br /&gt;%dem2 __1cFgreet6F_pc_&lt;br /&gt;&lt;br /&gt;__1cFgreet6F_pc_ == char*greet()&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;char*greet() has been mangled to __1cFgreet6F_pc_ by the&amp;nbsp;C++ compiler. That's the reason why the static linker (ld) couldn't match the symbol in the object file.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Note that a C compiler that complies with the C99 standard may mangle some names. For example, on systems in which linkers cannot accept extended characters, a C compiler may encode the universal character name in forming valid external identifiers. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&amp;nbsp; &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;How to solve this problem?&lt;/strong&gt; &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&amp;nbsp; &lt;/div&gt;&lt;div style="text-align: justify;"&gt;The C++ standard provides a mechanism called linkage specification to enables smooth compilation of mixed code. Linkage between C++ and non-C++ code fragments is called language linkage. All function types, function names, and variable names have a default C++ language linkage. Language linkage can be achieved using the following linkage specification &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&amp;nbsp; &lt;/div&gt;&lt;div style="text-align: justify;"&gt;The string-literal specifies the linkage associated with a particular function, for example, C and C++. Every C++ implementation provides for linkage to functions written in C language ("C") and linkage to C++ ("C++"). &lt;/div&gt;&lt;div style="text-align: justify;"&gt;The solution to the problem under discussion is to ask the C++ compiler to use C mangling for the external functions to be called, so we can use the functionality of external C functions from C++ code, without any issues. We can accomplish this using the linkage to C. The following declaration of greet() in greet.h should resolve the problem: &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace;"&gt;extern "C" char *greet();&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Because we were calling C code from a C++ program, C linkage was used for the routine greet(). The linkage directive extern "C" tells the compiler to change from C++ mangling to C mangling for the function, and to use C calling conventions while sending external information to the linker. In other words, the C linkage specification forces the C++ compiler to adopt C conventions, which are not the same as C++ conventions. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;So, let's modify the header greet.h, and recompile: &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;%cat greet.h&lt;br /&gt;#if defined __cplusplus&lt;br /&gt;        extern "C" {&lt;br /&gt;#endif&lt;br /&gt;&lt;br /&gt;        char *greet();&lt;br /&gt;&lt;br /&gt;#if defined __cplusplus&lt;br /&gt;    }&lt;br /&gt;#endif&lt;br /&gt;&lt;br /&gt;%cc -G -o libgreet.so greet.c&lt;br /&gt;%CC -lgreet mixedcode.cpp&lt;br /&gt;%./a.out&lt;br /&gt;Hello!&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;It works! Since the header greet.h was used in both C and C++ files, it is necessary to guard extern "C" with the C++ compiler's predefined macro _cplusplus. This is because the C compiler doesn't recognize the "C" portion of extern "C", and throws an error message for the same.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Let's have a look at the symbol table of mixedcode.o one more time &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&amp;nbsp; &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;%CC -c -lgreet mixedcode.cpp&lt;br /&gt;%elfdump -s mixedcode.o&lt;br /&gt;&lt;br /&gt;Symbol Table Section:  .symtab&lt;br /&gt;index    value       size     type bind oth ver shndx       name&lt;br /&gt;[0]  0x00000000 0x00000000  NOTY LOCL  D    0 UNDEF&lt;br /&gt;[1]  0x00000000 0x00000000  FILE LOCL  D    0 ABS         mixedcode.cpp&lt;br /&gt;[2]  0x00000000 0x00000000  SECT LOCL  D    0 .rodata&lt;br /&gt;[3]  0x00000000 0x00000000  FUNC GLOB  D    0 UNDEF     &lt;br /&gt;    __1cDstd2l6Frn0ANbasic_ostream4Ccn0ALchar_traits4Cc____pkc_2_&lt;br /&gt;[4]  0x00000000 0x00000000  FUNC GLOB  D    0 UNDEF       greet&lt;br /&gt;[5]  0x00000000 0x00000000  NOTY GLOB  D    0 UNDEF       __1cDstdEcout_&lt;br /&gt;[6]  0x00000010 0x00000050  FUNC GLOB  D    0 .text       main&lt;br /&gt;[7]  0x00000000 0x00000000  NOTY GLOB  D    0 ABS         __fsr_init_value&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&amp;nbsp;The function name greet was not mangled by the C++ compiler, and hence the linker could find the symbol in the object file and was able to build the executable. &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-552367572601381345?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/552367572601381345/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/mixed-language-programming-and-external.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/552367572601381345'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/552367572601381345'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/mixed-language-programming-and-external.html' title='Mixed-Language Programming and External Linkage'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-8841445323417336157</id><published>2010-08-06T01:44:00.000-07:00</published><updated>2010-08-06T01:45:46.757-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='c++'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><title type='text'>Name Mangling in C++</title><content type='html'>&lt;div style="text-align: justify;"&gt;When C++ compilers compile a C++ program, it encodes all function names and certain other identifiers to include type and scoping information. This encoding process is called name mangling. Linker uses these mangled names to ensure type-safe linkage. These mangled names appear in the object files and final executable file.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;What's a symbol?&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;In every C++ program/library/object file, all non-static functions are represented in the binary file as symbols. These symbols are special text strings that uniquely identify a function in the program, library or object file &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;The Need for Name Mangling:&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;C language programs does not use name mangling, because in C no two non-static functions can have the same name. i.e., the symbol name is the same as the function name: the symbol of myfunc will be myfunc&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Because C++ allows overloading (different functions with the same name but different number of arguments) and has many features C does not, like classes, member functions, exception specifications — it is not possible to simply use the function name as the symbol name. To solve that, C++ uses name mangling, which encodes the function name and all the necessary information (like the number and size of the arguments) into some special string which only the compiler knows about &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;eg.,&lt;/div&gt;&lt;div style="text-align: justify;"&gt;bpte4500s001:/sunbuild1/giri/testcases/% nm hide.o&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;hide.o:&lt;br /&gt;&lt;br /&gt;[Index]   Value      Size    Type  Bind  Other Shndx   Name&lt;br /&gt;[3]     |        16|      56|FUNC |GLOB |3    |2      |__1cKCRectangleKset_values6Mii_v_&lt;br /&gt;[4]     |         0|       0|NOTY |GLOB |0    |ABS    |__fsr_init_value&lt;br /&gt;[1]     |         0|       0|FILE |LOCL |0    |ABS    |hide.cpp&lt;br /&gt;[2]     |        88|      32|FUNC |GLOB |2    |2      |main&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;, Courier, monospace; font-size: x-small;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;"__1cKCRectangleKset_values6Mii_v_" is the mangled name&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;But this kind of scheme is undesirable for the developers because the names are difficult to read &amp;amp; debug&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Two utilities are available with Sun Studio C/C++ compiler collection to convert the mangled names to their original source code names:&lt;/div&gt;&lt;div style="text-align: justify;"&gt;1) c++filt &amp;amp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;2) dem&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;C++filt is a filter that demangles (decodes) mangled names.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;bpte4500s001% echo __1cKCRectangleKset_values6Mii_v_ | c++filt&lt;/div&gt;&lt;div style="text-align: justify;"&gt;void CRectangle::set_values(int,int)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;"dem" is another utility to demangle C++ names&lt;/div&gt;&lt;div style="text-align: justify;"&gt;bpte4500s001% dem __1cKCRectangleKset_values6Mii_v_&lt;/div&gt;&lt;div style="text-align: justify;"&gt;__1cKCRectangleKset_values6Mii_v_ == void CRectangle::set_values(int,int)&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;Note:&lt;/strong&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;C++ standard does not define how names have to be mangled; thus every compiler mangles names in its own way. Some compilers even change their name mangling algorithm between different versions. This could be a problem if the developers hack &amp;amp; rely on how compiler mangles the C++ symbols, as the same algorithm may not work with the next version of C++ compiler&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-8841445323417336157?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/8841445323417336157/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/name-mangling-in-c.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8841445323417336157'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8841445323417336157'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/name-mangling-in-c.html' title='Name Mangling in C++'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-34752858497372774</id><published>2010-08-05T07:27:00.000-07:00</published><updated>2010-08-06T00:34:01.245-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='c++'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><category scheme='http://www.blogger.com/atom/ns#' term='arrays'/><title type='text'>Interview qeustions on C/C++</title><content type='html'>&lt;strong&gt;1. What is the size of the structure,&amp;nbsp;assume int to be 4 bytes and float to be 4 bytes.&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;struct {&lt;br /&gt;    enum  {&lt;br /&gt;        integer,&lt;br /&gt;        floating&lt;br /&gt;    } type;&lt;br /&gt;    union {&lt;br /&gt;        int a;&lt;br /&gt;        float b;&lt;br /&gt;    };&lt;br /&gt;} t1;&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;&lt;strong&gt;Answer:&lt;/strong&gt; The enum would take one integer (4) and other union together will take one more space of larget between two (4), so total 8 bytes.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;suppose the structure delcaration is changes as below, then what would be the size?&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;struct {&lt;br /&gt;    enum type {&lt;br /&gt;        integer,&lt;br /&gt;        floating&lt;br /&gt;    } ;&lt;br /&gt;    union {&lt;br /&gt;        int a;&lt;br /&gt;        float b;&lt;br /&gt;    };&lt;br /&gt;} t1;&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;&lt;strong&gt;Answer:&lt;/strong&gt; This would result in compilation error, as there is no member of 'type'&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;2. What doe the following function do? can it be given a better name?&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;DT* func(DT* a, const DT* b)&lt;br /&gt;{&lt;br /&gt;    DT *c = a;&lt;br /&gt;    while(*a++ = *b++);&lt;br /&gt;    return c;&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;&lt;strong&gt;Answer:&lt;/strong&gt; Assuming that DT is an integer or char, the function would copy data from b to a, untill a zero in b is obtained, zero is also copied, so it can be renamed as string copy function.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;3. Is the out put of line one and two inside the loop same, or different?&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;int a[100][100];&lt;br /&gt;for(int i = 0; i&amp;lt;100; i++) {&lt;br /&gt;    for(int j = 0; j&amp;lt;100; j++) {&lt;br /&gt;        printf("%d", a[i][j]);&lt;br /&gt;        printf("%d", a[j][i]);&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;&lt;strong&gt;Answer:&lt;/strong&gt; The output would be different as they refer to different row and colum, but at the end they out put all the data in the two dimentional array. &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;If one needs to be prefered over the other, which one will you prefer? and why?&lt;/strong&gt; &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Answer:&lt;/strong&gt; The first one will be faster as it has less cache miss in case of a cache enabled system compared to the second one, so in a practical system the using first line would be faster, and so it should be prefered. Theoretically if memory access does not use cache, then both will be same in terms of time taken.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;4. What is function overloading? how does compiler will know which function to call?&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;class{ &lt;br /&gt;    void func(int a);&lt;br /&gt;    void func(int a, int b);&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;&lt;strong&gt;Answer:&lt;/strong&gt; Having many function definitions for the same functions with different number of arguments is called function overloading, and the compiler will decide about the functions by seeing the type and number of params passed to the function call, and decide on which function to call at compile time.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Suppose if the function is defined below with a default argument and when calling if it is not passed then how would compiler decide about function?&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;class{ &lt;br /&gt;    void func(int a);&lt;br /&gt;    void func(int a, int b = 0);&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;&lt;strong&gt;Answer:&lt;/strong&gt; Then the compiler wont be able to decide, and it will throw a compile time error.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-34752858497372774?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/34752858497372774/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/interview-qeustions-on-cc.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/34752858497372774'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/34752858497372774'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/interview-qeustions-on-cc.html' title='Interview qeustions on C/C++'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-7756859560259920122</id><published>2010-08-04T07:50:00.000-07:00</published><updated>2010-08-04T07:50:46.567-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>First bit set in an Integer</title><content type='html'>Write a C code which returns the position of the first bit set.fot eg. for number 104(1101000) output will be 4.&lt;br /&gt;&lt;br /&gt;You need to right shift the number untill the number becomes zero and count the number of times right shifted, then you subtract it from the size of an interger (32 bit on a 32 bit machine), you will get the answer. Here is the code for your reference.&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;int fbs(unsigned int num)&lt;br /&gt;{&lt;br /&gt;    int pos = -1;&lt;br /&gt;    while(num!=0)&lt;br /&gt;    {&lt;br /&gt;        num &amp;lt;&amp;lt;= 1;&lt;br /&gt;        pos++;&lt;br /&gt;    }&lt;br /&gt;    return 32 - pos;&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-7756859560259920122?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/7756859560259920122/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/first-bit-set-in-integer.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7756859560259920122'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7756859560259920122'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/first-bit-set-in-integer.html' title='First bit set in an Integer'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-1438379565845251161</id><published>2010-08-04T07:47:00.000-07:00</published><updated>2010-08-04T07:47:59.417-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>Mod 16 without using arithmatic</title><content type='html'>Write a function which takes an integer value as an argument and return its mod 16 value without using these (%,+,_,/) arithmetic operations&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;int mod16(int a)&lt;br /&gt;{&lt;br /&gt;    return a&amp;gt;&amp;gt;4;&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;The 4 bits left shift will give mod 16.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-1438379565845251161?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/1438379565845251161/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/mod-16-without-using-arithmatic.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1438379565845251161'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1438379565845251161'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/mod-16-without-using-arithmatic.html' title='Mod 16 without using arithmatic'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-2726903152559653616</id><published>2010-08-04T06:10:00.000-07:00</published><updated>2010-08-04T06:10:48.035-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='dynamic linking'/><category scheme='http://www.blogger.com/atom/ns#' term='dll programming'/><category scheme='http://www.blogger.com/atom/ns#' term='static linking'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>what is the difference between dynamic and static linking? which is better?</title><content type='html'>&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;A dynamic-link library (DLL) is an executable file that acts as a shared library of functions. Dynamic linking provides a way for a process to call a function that is not part of its executable code. The executable code for the function is located in a DLL, which contains one or more functions that are compiled, linked, and stored separately from the processes that use them. DLLs also facilitate the sharing of data and resources. Multiple applications can simultaneously access the contents of a single copy of a DLL in memory.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Dynamic linking differs from static linking in that it allows an executable module (either a .dll or .exe file) to include only the information needed at run time to locate the executable code for a DLL function. In static linking, the linker gets all of the referenced functions from the static link library and places it with your code into your executable.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Using dynamic linking instead of static linking offers several advantages. DLLs save memory, reduce swapping, save disk space, upgrade easier, provide after-market support, provide a mechanism to extend the MFC library classes, support multilanguage programs, and ease the creation of international versions.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;In case of free software licenses also, there are provisions with LGPL, using which you dont have to share the code which are linked dynamically.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-2726903152559653616?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/2726903152559653616/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/what-is-difference-between-dynamic-and.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2726903152559653616'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2726903152559653616'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/08/what-is-difference-between-dynamic-and.html' title='what is the difference between dynamic and static linking? which is better?'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-2106452553977631411</id><published>2010-07-15T09:25:00.000-07:00</published><updated>2011-09-20T00:16:37.390-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>Wipro C/C++ Interview Questions</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div&gt;&lt;b&gt;1. What is the main difference between the C++ class and the C structure?&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;Answer :&lt;/b&gt; Both in C++ class and C structure you can have member functions and member variables, but in &lt;strike&gt;C++ the member functions are inside the memory allocated for the object, but in C structures they will reside out the memory allocated for the structure.&lt;/strike&gt;&amp;nbsp; C++ the member functions are passed with 'this' pointer which&amp;nbsp;pointer&amp;nbsp;to the objects and rest of the things are taken care by compiler with the help of 'this' pointer. &lt;strike&gt;This is done by compiler during compile time,&lt;/strike&gt; and this remains the main difference and helps in achieving the object oriented nature of C++.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;2. What is the difference between the two declarations below using volatile keyword.&lt;/b&gt;&lt;br /&gt;&lt;span style="color: #7f6000; font-family: 'Courier New';"&gt;volatile struct reg_map {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; int reg_r1;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; int reg_r2;&lt;br /&gt;};&lt;br /&gt;&lt;br /&gt;struct reg_map {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; volatile int reg_r1;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; volatile int reg_r2;&lt;br /&gt;};&lt;/span&gt;&lt;br /&gt;&lt;b&gt;Answer :&lt;/b&gt; In the first case it is up to the compiler to make all the variables as volatile, but in second case the compiler will always make the members as volatile, so that the purpose is served. In first case we need to check if the compiler really makes all members volatile or not, and if it does not, then it does not serve the purpose.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;3. I have a union declared as below &lt;/b&gt;&lt;span style="color: #7f6000; font-family: 'Courier New';"&gt;&amp;nbsp;&amp;nbsp; union&amp;nbsp; ex_union {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; int a;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; short int ar[2];&lt;br /&gt;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&amp;nbsp;&lt;/div&gt;&lt;div&gt;if I assign the value 0x112233 to a, what would be the values of elements ar[0] and ar[1]&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Answer:&lt;/b&gt; Considering it to be little endian machine, the value would be, 0x2233 and 0x0011 respectively, Because in Little endian end byte will be in little address and first byte will be in high address.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;4. Assume you have a function with two params a and b, and you need to return an int after processing like below.&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;span style="color: #7f6000; font-family: 'Courier New';"&gt;&amp;nbsp;&amp;nbsp; int compare(int a, int b)&lt;br /&gt;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if a&amp;gt;b return 1&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if b&amp;gt;a return -1&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if a = b, return 0&lt;br /&gt;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;/div&gt;&lt;div&gt;you need to write this function without using if else, switch and ternary operators, how do you do it?&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;Answer:&lt;/b&gt; The purpose of this question is, to reduce the pipe line flush during branch, since here there is 50% chance of branch, we need to avoid any branch instructions.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color: #7f6000; font-family: 'Courier New';"&gt;int compare(int a, int b)&lt;br /&gt;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; int x, m, s;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; x = a - b;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // find the difference&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; m = x || 1;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // if magnitude not zero make it 1&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; s = (x &amp;amp; (1 &amp;lt;&amp;lt; 31));&amp;nbsp;&amp;nbsp; // get the sign &lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; __asm sar s, 31&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // extend the sign to make it -1&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; return s | m;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // or sign and magnitude&lt;br /&gt;}&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;div&gt;This can also be written like below, but it will introduce branch in the generated x86 code, check it in visual studio.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color: #7f6000; font-family: 'Courier New';"&gt;int compare (int a, int b)&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color: #7f6000; font-family: 'Courier New';"&gt;{&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color: #7f6000; font-family: 'Courier New';"&gt;&amp;nbsp;&amp;nbsp; int x&amp;nbsp; = 0;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color: #7f6000; font-family: 'Courier New';"&gt;&amp;nbsp;&amp;nbsp; (a&amp;gt;b) &amp;amp;&amp;amp; (x = 1) || (a&amp;lt;b) &amp;amp;&amp;amp; (x = -1);&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color: #7f6000; font-family: 'Courier New';"&gt;&amp;nbsp;&amp;nbsp; return x;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color: #7f6000; font-family: 'Courier New';"&gt;}&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: #7f6000; font-family: 'Courier New';"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;b&gt;Update:&lt;/b&gt;&lt;br /&gt;In both the above cases, the compiler will generate the the branch instruction, which is same as the if, else and thus defeating the purpose, I have an solution for it, after the&amp;nbsp;subtraction find the sign of the result using below function (code) and it wont generate the branch instruction.&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;"&gt;&lt;code&gt;int IntSign(int num)&lt;br /&gt;{&lt;br /&gt;    int sign = (num !=0) | -(int)((unsigned int)num &amp;gt;&amp;gt; (sizeof(int)*8 - 1));&lt;br /&gt;    return sign;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;The assembly code generate for the calculation is as below (visual studio for x86)&lt;br /&gt;&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;"&gt;&lt;code&gt;    int sign = (num !=0) | -(int)((unsigned int)num &amp;gt;&amp;gt; (sizeof(int)*8 - 1));&lt;br /&gt;0041140E  xor         eax,eax &lt;br /&gt;00411410  cmp         dword ptr [num],0 &lt;br /&gt;00411414  setne       al   &lt;br /&gt;00411417  mov         ecx,dword ptr [num] &lt;br /&gt;0041141A  shr         ecx,1Fh &lt;br /&gt;0041141D  neg         ecx  &lt;br /&gt;0041141F  or          eax,ecx &lt;br /&gt;00411421  mov         dword ptr [sign],eax &lt;br /&gt;    return sign;&lt;br /&gt;00411424  mov         eax,dword ptr [sign] &lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-2106452553977631411?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/2106452553977631411/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/07/wipro-cc-interview-questions.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2106452553977631411'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2106452553977631411'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/07/wipro-cc-interview-questions.html' title='Wipro C/C++ Interview Questions'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-2896611385295763300</id><published>2010-07-09T02:15:00.000-07:00</published><updated>2010-07-09T02:25:31.761-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><category scheme='http://www.blogger.com/atom/ns#' term='Embedded'/><title type='text'>Embedded Systems Questions for Interview</title><content type='html'>&lt;div align="justify" style="text-align: center;"&gt;&lt;b&gt;Embedded Systems Questions for Interview&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;1) What is a 'volatile' variable?&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Volatile is a keyword to specify the compiler that this variable value can change any time, so compiler should always read its value from it's address, and not to use temporary registers to store its value and use in later part of the code. &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;This is specially important to handle the memory mapped registers which are mapped as some variables or structures in embedded systems, such as hardward status registers etc, whose value can be changed anytime, depending on the hardware state. &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Examples of volatile variables are, &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Hardware registers in peripherals (for example, status registers)&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Non-automatic variables referenced within an interrupt service routine&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Variables shared by multiple tasks in a multi-threaded application&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;Can a volatile be constant? like&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;volatile const a; &lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Yes it can be, it means that, it can be changes by hardware state chage, but its read only register in hardware, so code should not try to modify it.&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;Can a pointer be volatile ? Explain&lt;/b&gt;. &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Yes, although this is not very common. An example is when an interrupt service routine modifies a pointer to a buffer&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;What's wrong with the following function? &lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;int square(volatile int *ptr)&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;{&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;return *ptr * *ptr;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;}&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;This one is wicked. The intent of the code is to return the square of the value pointed to by *ptr . However, since *ptr points to a volatile parameter, the compiler will generate code that looks something like this: &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;int square(volatile int *ptr)&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;{&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;int a,b;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;a = *ptr;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;b = *ptr;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;return a * b;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;}&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Because it's possible for the value of *ptr to change unexpectedly, it is possible for a and b to be different. Consequently, this code could return a number that is not a square! The correct way to code this is:&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;long square(volatile int *ptr)&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;{&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;int a;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;a = *ptr;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;return a * a;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;}&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;2) What is a 'const' variable? &lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;In simple terms 'const' means 'read only'. Its value is not changed by any part of the code executed. So compiler can optimize by taking this info, and also it will give warning when user try to change the value of this variable by mistake. &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;If the candidate gets the answer correct, I'll ask him these supplemental questions: &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;What do the following declarations mean?&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;const int a;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;int const a;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;const int *a;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;int * const a;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;int const * a const&lt;/span&gt;;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;The first two mean the same thing, namely a is a const (read-only) integer. The third means a is a pointer to a const integer (that is, the integer isn't modifiable, but the pointer is). The fourth declares a to be a const pointer to an integer (that is, the integer pointed to by a is modifiable, but the pointer is not). The final declaration declares a to be a const pointer to a const integer (that is, neither the integer pointed to by a, nor the pointer itself may be modified). If the candidate correctly answers these questions, I'll be impressed. &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Even thouugh any program can be written without this keyword, it's good to use this, since it will help the one who is reading the program to understand the code easily by the information that the variable's value wont get changed. So using const keyword will help reducing the bugs in the code. &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;3) Which is the best way to write Loops?&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;The best way is to write count down loops and compiler can generate better machine code for it than the count up loops. In count down at loop termination, it needs to generate one instructions (SUBS), which subtracts as well as check the zero flag, but in count up case it has to add and compare with a constant, which takes two instructions.&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;4) What is loop unrolling?&amp;nbsp; &lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Small loops can be unrolled for higher performance, with the disadvantage of increased codesize. When a loop is unrolled, a loop counter needs to be updated less often and fewer branches are executed. If the loop iterates only a few times, it can be fully unrolled, so that the loop overhead completely disappears. &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;int CountBitOne(uint n)&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;{&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;int bits = 0; &lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;while (n != 0)&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;if (n &amp;amp; 1) bits++;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;n &amp;gt;&amp;gt; = 1;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;return bits;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;} &lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;int CountBitOne(uint n) &lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;{ &lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp; int bits = 0; &lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;while (n != 0)&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;if (n &amp;amp; 1) bits++;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;if (n &amp;amp; 2) bits++;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;if (n &amp;amp; 4) bits++;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;if (n &amp;amp; 8) bits++;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;n &amp;gt;&amp;gt; = 4;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;&amp;nbsp; return bits;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;}&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;5) How are local and Global variables are allocated by compiler.&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Normally, cpu registers are allocated for local variables, but if the address of that local variable is used by some code, then it wont allocate register but access from memory, thus result in un-optimized code. Gobal variables always use memory, so access is slower, so always use global only when it is absolutely neccessary.&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;6) Which is better a char, short or int type for optimization?&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Where possible, it is best to avoid using char and short as local variables. For the types char and short the compiler needs to reduce the size of the local variable to 8 or 16 bits after each assignment. This is called sign-extending for signed variables and zeroextending for unsigned variables. It is implemented by shifting the register left by 24 or 16 bits, followed by a signed or unsigned shift right by the same amount, taking two instructions (zero-extension of an unsigned char takes one instruction). &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;These shifts can be avoided by using int and unsigned int for local variables. This is particularly important for calculations which first load data into local variables and then process the data inside the local variables. Even if data is input and output as 8- or 16-bit quantities, it is worth considering processing them as 32bit quantities&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;7) How to reduce function call overhead in ARM based systems&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Try to ensure that small functions take four or fewer arguments. These will not use the stack for argument passing. It will copied into registers.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;If a function needs more than four arguments, try to ensure that it does a significant amount of work, so that the cost of passing the stacked arguments is outweighed.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Pass pointers to structures instead of passing the structure itself.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Put related arguments in a structure, and pass a pointer to the structure to functions. This will reduce the number of parameters and increase readability.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Minimize the number of long long parameters, as these take two argument words. This also applies to doubles if software floating-point is enabled.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Avoid functions with a parameter that is passed partially in a register and partially on the stack (split-argument). This is not handled efficiently by the current compilers: all register arguments are pushed on the stack.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Avoid functions with a variable number of parameters. Varargs functions&amp;nbsp;&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;8) What is a pure function in ARM terminology? &lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Pure functions are those which return a result which depends only on their arguments. They can be thought of as mathematical functions: they always return the same result if the arguments are the same. To tell the compiler that a function is pure, use the special declaration keyword &lt;i&gt;__pure&lt;/i&gt;. &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;__pure int square(int x) &lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #783f04; font-family: Courier New;"&gt;{ &lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="font-family: Courier New;"&gt;&lt;span style="color: #783f04;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;return x * x; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="font-family: Courier New;"&gt;&lt;span style="color: #783f04;"&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;9) What are inline functions?&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;&amp;nbsp;&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;The ARM compilers support inline functions with the keyword __inline. This results in each call to an inline function being substituted by its body, instead of a normal call. This results in faster code, but it adversely affects code size, particularly if the inline function is large and used often.&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;&lt;span style="color: #666666;"&gt;Preprocessor &lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;10) Using the #define statement, how would you declare a manifest constant that returns the number of seconds in a year? Disregard leap years in your answer.&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;#define SECONDS_PER_YEAR &lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;(60 * 60 * 24 * 365)UL&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;The purpose of this question is to test the following: &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;ol&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Basic knowledge of the #define syntax (for example, no semi-colon at the end, the need to parenthesize, and so on) &lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;An understanding that the pre-processor will evaluate constant expressions for you. Thus, it is clearer, and penalty-free, to spell out how you are calculating the number of seconds in a year, rather than actually doing the calculation yourself &lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;A realization that the expression will overflow an integer argument on a 16-bit machinehence the need for the L, telling the compiler to treat the variable as a Long &lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;As a bonus, if you modified the expression with a UL (indicating unsigned long), then you are off to a great start. And remember, first impressions count!&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;11) Write the "standard" MIN macro-that is, a macro that takes two arguments and returns the smaller of the two arguments.&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;#define MIN(a,b) ((a)&amp;lt;(b)?(a):(b))&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;The purpose of this question is to test the following: &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;ol&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Basic knowledge of the #define directive as used in macros. This is important because until the inline operator becomes part of standard C, macros are the only portable way of generating inline code. Inline code is often necessary in embedded systems in order to achieve the required performance level &lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Knowledge of the ternary conditional operator. This operator exists in C because it allows the compiler to produce more optimal code than an if-then-else sequence. Given that performance is normally an issue in embedded systems, knowledge and use of this construct is important&amp;nbsp; &lt;div&gt;&amp;nbsp;&amp;nbsp;&lt;/div&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Understanding of the need to very carefully parenthesize arguments to macros&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;I also use this question to start a discussion on the side effects of macros, for example, &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;br /&gt;what happens when you write code such as:&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&lt;br /&gt;least = MIN(*p++, b);&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;In this case, the expression is replaced by,&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;*ptr is compared with b, then ptr is incremented to point to next integer, suppose *ptr is small, then *ptr is assigned to least, and ptr is incremented again.&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;So the result will be integer at (ptr + sizeof(int)).&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;12) What is the purpose of the preprocessor directive #error?&lt;/b&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Answer to this question does not need to be known, this is normally explained in the appendices, only nerds normally look into the appendices to see the answers for such questions. Normal folks dont be knowing the answer to this unless they happend to see this somewhere else while doing some project.&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;13) Infinite loops often arise in embedded systems. How does you code an infinite loop in C?&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;There are several solutions to this question. One is, &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;while(1)&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;{&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;}&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Other is using for loop, but here things are not pretty clear as to what is going on. &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;for(;;)&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;{&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;}&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Even though both serve the same perpose, its always better to know why you are using the first or second. So when you are asked about such questions you must answer with confidence that both are right, and just matter which way you wish to code it, anyways finally compiler would optimize and generate the same code for it. So dont ever say, I was taught to do it this way, and so never thought about the other ways.&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;There is another way of doing it, i.e. by using goto statement, goto is very basic keyword, which is more like an assembly jump instruction, if one finds more confortable with goto then possibly he works closely with assembly language, or with FORATN.&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;loop:&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;...&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;...&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;goto loop;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;14) Data declarations&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;a) &lt;span style="color: #7f6000; font-family: Courier New;"&gt;int a;&lt;/span&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;An integer &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;b) &lt;span style="color: #7f6000; font-family: Courier New;"&gt;int *a;&lt;/span&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;A pointer to an integer&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;c) &lt;span style="color: #7f6000; font-family: Courier New;"&gt;int **a;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;A pointer to a pointer to an integer&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;d) &lt;span style="color: #7f6000; font-family: Courier New;"&gt;int a[10];&lt;/span&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;An array of 10 integers&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;e) &lt;span style="color: #7f6000; font-family: Courier New;"&gt;int *a[10];&lt;/span&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;An array of 10 pointers to integers&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;f) &lt;span style="color: #7f6000; font-family: Courier New;"&gt;int (*a)[10];&lt;/span&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;A pointer to an array of 10 integers&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;g) &lt;span style="color: #7f6000; font-family: Courier New;"&gt;int (*a)(int);&lt;/span&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;A pointer to a function a that takes an integer argument and returns an integer&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;h) &lt;span style="color: #7f6000; font-family: Courier New;"&gt;int (*a[10])(int);&lt;/span&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;An array of 10 pointers to functions that take an integer argument and return an integer &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;People often claim that a couple of these are the sorts of thing that one looks up in textbooks and I agree. While writing this article, I consulted textbooks to ensure the syntax was correct. However, I expect to be asked this question (or something close to it) when I'm being interviewed. Consequently, I make sure I know the answers, at least for the few hours of the interview. Candidates who don't know all the answers (or at least most of them) are simply unprepared for the interview. If they can't be prepared for the interview, what will they be prepared for?&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;15) What are the uses of the keyword static? &lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;This simple question is rarely answered completely. Static has three distinct uses in C:&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify"&gt;A variable declared static within the body of a function maintains its value between function invocations&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify"&gt;A variable declared static within a module, (but outside the body of a function) is accessible by all functions within that module. It is not accessible by functions within any other module. That is, it is a localized global. &lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&amp;nbsp;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify" style="text-align: justify;"&gt;Functions declared static within a module may only be called by other functions within that module. That is, the scope of the function is localized to the module within which it is declared&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;Most candidates get the first part correct. A reasonable number get the second part correct, while a pitiful number understand the third answer. This is a serious weakness in a candidate, since he obviously doesn't understand the importance and benefits of localizing the scope of both data and code.&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;b&gt;16) Bit manipulation : Embedded systems always require the user to manipulate bits in registers or variables. Given an integer variable a, write two code fragments. The first should set bit 3 of a. The second should clear bit 3 of a. In both cases, the remaining bits should be unmodified.&lt;/b&gt;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;These are the three basic responses to this question: &lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify" style="text-align: justify;"&gt;&lt;ol&gt;&lt;li&gt;&lt;div&gt;No idea. The interviewee cannot have done any embedded systems work &lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div&gt;Use bit fields. Bit fields are right up there with trigraphs as the most brain-dead portion of C. Bit fields are inherently non-portable across compilers, and as such guarantee that your code is not reusable. The moral: never let a non-embedded person anywhere near a real piece of hardware &lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div&gt;Use #defines and bit masks. This is a highly portable method and is the one that should be used. &lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;&lt;div align="justify"&gt;My optimal solution to this problem would be: &lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;#define BIT3 (0x1 &amp;lt;&amp;lt; 3) &lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;static int a;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;void set_bit3(void) {&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;a |= BIT3;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;}&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;void clear_bit3(void) { &lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;a &amp;amp;= ~BIT3;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;}&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;Some people prefer to define a mask together with manifest constants for the set and clear values. This is also acceptable. The element that I'm looking for is the use of manifest constants, together with the |= and &amp;amp;= ~ constructs&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&lt;b&gt;17) Accessing fixed memory locations&lt;/b&gt;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;Embedded systems are often characterized by requiring the programmer to access a specific memory location. On a certain project it is required to set an integer variable at the absolute address 0x67a9 to the value 0xaa55. The compiler is a pure ANSI compiler. Write code to accomplish this task.&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;This problem tests whether you know that it is legal to typecast an integer to a pointer in order to access an absolute location. The exact syntax varies depending upon one's style. However, I would typically be looking for something like this:&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;int *ptr; &lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;ptr = (int *)0x67a9;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;*ptr = 0xaa55;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;A more obscure approach is: &lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;*(int * const)(0x67a9) = 0xaa55;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;Even if your taste runs more to the second solution, I suggest the first solution when you are in an interview situation.&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&lt;b&gt;18) Interrupts and ISR&lt;/b&gt;&lt;/div&gt;&lt;div align="justify"&gt;Interrupts are an important part of embedded systems. Consequently, many compiler vendors offer an extension to standard C to support interrupts. Typically, this new keyword is __interrupt. The following code uses __interrupt to define an interrupt service routine (ISR). Comment on the code.&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;__interrupt double compute_area (double radius)&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;{&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;double area = PI * radius * radius;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;printf("\nArea = %f", area);&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;return area;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;}&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;This function has so much wrong with it, it's hard to know where to start:&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;ol&gt;&lt;li&gt;&lt;div align="justify"&gt;ISRs cannot return a value. If you don't understand this, you aren't hired&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify"&gt;ISRs cannot be passed parameters. See the first item for your employment prospects if you missed this&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify"&gt;On many processors/compilers, floating-point operations are not necessarily re-entrant. In some cases one needs to stack additional registers. In other cases, one simply cannot do floating point in an ISR. Furthermore, given that a general rule of thumb is that ISRs should be short and sweet, one wonders about the wisdom of doing floating-point math here&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify"&gt;In a vein similar to the third point, printf() often has problems with reentrancy and performance. &lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;If you missed points three and four, I wouldn't be too hard on you. Needless to say, if you got these last two points, your employment prospects are looking better and better.&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&lt;b&gt;Code examples&lt;/b&gt;&lt;br /&gt;&lt;b&gt;19) What does the following code output and why?&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;void foo(void)&lt;br /&gt;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;unsigned int a = 6;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;int b = -20;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;(a+b &amp;gt; 6) ? puts("&amp;gt; 6") :puts("&amp;lt;= 6");&lt;br /&gt;}&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;This question tests whether you understand the integer promotion rules in C-an area that I find is very poorly understood by many developers. Anyway, the answer is that this outputs "&amp;gt; 6." The reason for this is that expressions involving signed and unsigned types have all operands promoted to unsigned types. Thus comes a very large positive integer and the expression evaluates to greater than 6. This is a very important point in embedded systems where unsigned data types should be used frequently. If you get this one wrong, you are perilously close to not getting the job.&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&lt;b&gt;20) Comment on the following code fragment.&lt;/b&gt;&lt;br /&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;unsigned int zero = 0;&lt;br /&gt;unsigned int compzero = 0xFFFF;&lt;br /&gt;/*1's complement of zero */&lt;/span&gt;&lt;br /&gt;On machines where an int is not 16 bits, this will be incorrect. &lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;It should be coded: unsigned int compzero = ~0; &lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;This question really gets to whether the candidate understands the importance of word length on a computer. In my experience, good embedded programmers are critically aware of the underlying hardware and its limitations, whereas computer programmers tend to dismiss the hardware as a necessary annoyance.&lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;By this stage, candidates are either completely demoralized-or they're on a roll and having a good time. If it's obvious that the candidate isn't very good, then the test is terminated at this point. However, if the candidate is doing well, then I throw in these supplemental questions.&lt;br /&gt;&lt;/div&gt;&lt;div align="justify"&gt;These questions are hard, and I expect that only the very best candidates will do well on them. In posing these questions, I'm looking more at the way the candidate tackles the problems, rather than the answers. Anyway, have fun...&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;&lt;b&gt;Dynamic memory allocation&lt;/b&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;&lt;b&gt;21) Although not as common as in non-embedded computers, embedded systems do still dynamically allocate memory from the heap. What are the problems with dynamic memory allocation in embedded systems?&lt;/b&gt;&lt;br /&gt;Here, I expect the user to mention memory fragmentation, problems with garbage collection, variable execution time, and so on. This topic has been covered extensively in ESP , mainly by P.J. Plauger. His explanations are far more insightful than anything I could offer here, so go and read those back issues! Having lulled the candidate into a sense of false security, I then offer up&lt;br /&gt;this tidbit:&lt;br /&gt;&lt;/div&gt;&lt;div align="justify"&gt;What does the following code fragment output and why?&lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;char *ptr;&lt;br /&gt;if ((ptr = (char *)malloc(0)) == NULL) &lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000;"&gt;&lt;span style="font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;puts("Got a valid pointer");&lt;br /&gt;else &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000;"&gt;&lt;span style="font-family: Courier New;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;puts("Got a null pointer");&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;This is a fun question. I stumbled across this only recently when a colleague of mine advertently passed a value of 0 to malloc and got back a valid pointer! That is, the above code will output "Got a valid pointer." I use this to start a discussion on whether the interviewee thinks this is the correct thing for the library routine to do. Getting the right answer here is not nearly as important as the way you approach the problem and the rationale for your decision.&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&lt;b&gt;22. Typedef is frequently used in C to declare synonyms for pre-existing data types. It is also possible to use the preprocessor to do something similar. For instance, consider the following code fragment:&lt;/b&gt;&lt;br /&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;#define dPS struct s *&lt;br /&gt;typedef struct s * tPS;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;The intent in both cases is to define dPS and tPS to be pointers to structure s. Which method, if any, is preferred and why?&lt;/b&gt;&lt;/div&gt;&lt;div align="justify"&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;This is a very subtle question, and anyone who gets it right (for the right reason) is to be congratulated or condemned ("get a life" springs to mind). The answer is the typedef is preferred. Consider the declarations:&lt;br /&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;dPS p1,p2;&lt;br /&gt;tPS p3,p4;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;The first expands to:&lt;br /&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;struct s * p1, p2;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;which defines p1 to be a pointer to the structure and p2 to be an actual structure, which is probably not what you wanted. The second example correctly defines p3 and p4 to be pointers.&lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;&amp;nbsp;&lt;/div&gt;&lt;div align="justify"&gt;&lt;b&gt;Obscure syntax&lt;br /&gt;23. C allows some appalling constructs. Is this construct legal, and if so what does this code do?&lt;/b&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;int a = 5, b = 7, c;&lt;br /&gt;c = a+++b;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;This question is intended to be a lighthearted end to the quiz, as, believe it or not, this is perfectly legal syntax. The question is how does the compiler treat it? Those poor compiler writers actually debated this issue, and came up with the "maximum munch" rule, which stipulates that the compiler should bite off as big (and legal) a chunk as it can. Hence, this code is treated as:&lt;br /&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="color: #7f6000; font-family: Courier New;"&gt;c = a++ + b;&lt;/span&gt;&lt;/div&gt;&lt;div align="justify"&gt;Thus, after this code is executed, a = 6, b = 7, and c = 12.&lt;br /&gt;&lt;/div&gt;&lt;div align="justify"&gt;If you knew the answer, or guessed correctly, well done. If you didn't know the answer then I wouldn't consider this to be a problem. I find the greatest benefit of this question is that it is good for stimulating questions on coding styles, the value of code reviews, and the benefits of using lint.&lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-2896611385295763300?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/2896611385295763300/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/07/embedded-systems-questions-for.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2896611385295763300'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2896611385295763300'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/07/embedded-systems-questions-for.html' title='Embedded Systems Questions for Interview'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-1729119404738621254</id><published>2010-07-09T02:02:00.000-07:00</published><updated>2010-07-09T02:02:39.529-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Regedit'/><category scheme='http://www.blogger.com/atom/ns#' term='Login'/><category scheme='http://www.blogger.com/atom/ns#' term='Slow'/><category scheme='http://www.blogger.com/atom/ns#' term='Windows'/><category scheme='http://www.blogger.com/atom/ns#' term='Vista'/><category scheme='http://www.blogger.com/atom/ns#' term='MsConfig'/><category scheme='http://www.blogger.com/atom/ns#' term='Services'/><title type='text'>Windows Vista Slow Login Problem</title><content type='html'>&lt;div style="text-align: justify;"&gt;There are some programs registered at the startup, which makes the vista login very slow, about up to 3 mins, we need to removed them using msconfig.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;msconfig&amp;nbsp;-&amp;gt; services&amp;nbsp;-&amp;gt; hide all microsoft services&amp;nbsp; &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;uncheck these if they exist: xaudio, vongo, stllsvr,roxmediad89, installdriver table manager, cyberlink background, cyberlink task, Flexnet Licensing Services&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Then click on boot tab -&amp;gt;advanced options -&amp;gt; number of processors 2 -&amp;gt; maximum memory.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;I went from 2 min to 15 seconds bootup doing this. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;Also install TweakNow RegCleaner and remove all the unneccessary entries from the registry, it can also delete unneccessary temp files from the disk and also help in doing registry defragmentation. Its free and safe tool. It can be downloaded from &lt;a href="http://download.cnet.com/TweakNow-RegCleaner/3000-18512_4-10262639.html"&gt;here&lt;/a&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;You can also removed those entries related to them in the msconfig and services list using the below procedure.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;b&gt;How to Remove Entries From MSCONFIG Services&lt;/b&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Startup programs provide users with an easy way to load programs automatically each time the computer boots. The programs that start each time Windows starts are listed in an application called MSCONFIG. Even after disabling the programs, they are still listed in the MSCONFIG application in case you decide to re-enable them. You can prevent these services from being listed by editing the Windows registry&lt;/div&gt;&lt;ol style="text-align: justify;"&gt;&lt;li&gt;Click the Windows Start button and select "Run". Enter "regedit" in the text box and click the "Ok" button. This opens the Windows registry editor. &lt;/li&gt;&lt;li&gt;Navigate to the "HKEY_LOCAL_MACHINE \ Software \ Microsoft \ Shared Tools \ MSConfig \" key in the registry. When you click the "MSConfig" key, a list of subkeys is displayed. One of these is the services key, which holds the values you want to remove.&lt;/li&gt;&lt;li&gt;Click a program name in the "Services" directory that you want to delete from startup. Press the "Delete" key on your keyboard. Select "Yes" at the confirmation screen. The service is removed from MS Config startup. Continue to do this with each service you want to remove from MSCONFIG.&lt;/li&gt;&lt;/ol&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;b&gt;How to removed the service from the service list&lt;/b&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;b&gt;&amp;nbsp;&lt;/b&gt; &lt;/div&gt;&lt;div style="text-align: justify;"&gt;Normally it should not be necessary to manually delete a service. Uninstalling an application should remove its associated service (if any).&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;However, should it be necessary to manually remove a service:&lt;/div&gt;&lt;ol style="text-align: justify;"&gt;&lt;li&gt;Run Regedit or regedt32. &lt;/li&gt;&lt;li&gt;Fnd the registry entry:&amp;nbsp; HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Service&lt;/li&gt;&lt;li&gt;Find the service there and delete it&lt;/li&gt;&lt;/ol&gt;&lt;div style="text-align: justify;"&gt;You may wish to look at the keys and see what files the service was using and perhaps delete them also. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;b&gt;Note:&lt;/b&gt; &lt;/div&gt;&lt;ul style="text-align: justify;"&gt;&lt;li&gt;You will have to reboot before the list gets updated in server manager. &lt;/li&gt;&lt;li&gt;I have had it pointed out that some programs are cunning and prevent you from removing their service easily. (For example the spyware\malware called ‘Command Service’ - "cmdService".) These change the permissions to make it more difficult for you to delete them. For these you will have to right click on the ‘service’ in regedit (regedt32), go to permissions and grant the administrator full control before the service can be deleted&lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-1729119404738621254?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/1729119404738621254/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/07/windows-vista-slow-login-problem.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1729119404738621254'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1729119404738621254'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/07/windows-vista-slow-login-problem.html' title='Windows Vista Slow Login Problem'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-6164299633970932046</id><published>2010-05-15T22:40:00.000-07:00</published><updated>2010-07-17T07:49:05.753-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='puzzle'/><title type='text'>Ant and Spider Problem</title><content type='html'>&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Given a cube. A ant is placed in a corner and cannot move. A spider starts from the opposite corner, and can move along cube edges in any direction (x,y,z) with probablity 1/3. What is the expected number of steps for this spider to get to the ant?&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Let x represent the expected number of moves it takes to reach the ant when the spider is one move away (i.e., at any one of the three vertices of the cube adjacent to the ant). Let y represent the expected number of moves it takes to reach the ant when the spider is two moves away, and let z represent the expected number of moves it takes to reach the ant when the spider is three moves away (at the opposite vertex on the cube).&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Then z = 1 + y, since after the first move, the spider will be one move away. From this point, there is a (2/3) chance that the spider will move to a vertex adjacent to the ant and there is a (1/3) chance he will move back to his starting position,&amp;nbsp;Thus, y = 1 + (2/3)x + (1/3)z.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Similarly, x = 1 + (1/3)(0) + (2/3)(y). This system of 3 equations with 3 unknowns has solution z=10, y=9, and x=7. So, it will take 10 steps to reach the ant, on average, from the spider's initial position.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-6164299633970932046?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/6164299633970932046/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/ant-and-spider-problem.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/6164299633970932046'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/6164299633970932046'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/ant-and-spider-problem.html' title='Ant and Spider Problem'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-4874950161065527869</id><published>2010-05-11T22:36:00.000-07:00</published><updated>2010-07-17T07:49:05.753-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='puzzle'/><title type='text'>7 Bucket and Poison Problem</title><content type='html'>&lt;div style="text-align: justify;"&gt;There are 7 buckets with water, and one of them is poisoned. You have infinite number of flies, and if you put a fly in poisonous bucket, it will take seven days to die. You need to send your friend a non-poisonous bucket in 1 week, and also you need to find out which bucket is poisoned. How many least number of flies you need to it? and how do you do it?&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;1) One answer would be, You need one fly for this.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;b&gt;How? &amp;nbsp;&lt;/b&gt;You put the fly in any one of the bucket, and if it dies in one week then it is the poisonous one, and send any one of the other 6 to your friend, and if fly does not die, then its non-poisonous, and you need to send this to your friend and since you have sent to your friend in one week, now take your time and repeat to find out which has the poison with the same fly.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;2) Since first answer may be ridiculous, the second answer would be using 3 flies.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;b&gt;How? &lt;/b&gt;You need to number the buckets from 1 to 7 in binary and then assign one bit for each flies, and dip the fly in those buckets which has the corresponding bit set in the bucket number in binary, after seven days, if the fly dies consider it as 1 otherwise 0, and get the binary number for bucket which contains the poison.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-4874950161065527869?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/4874950161065527869/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/7-bucket-and-poison-problem.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4874950161065527869'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4874950161065527869'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/7-bucket-and-poison-problem.html' title='7 Bucket and Poison Problem'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-3947044345855924184</id><published>2010-05-11T19:08:00.000-07:00</published><updated>2010-07-17T07:49:05.754-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='puzzle'/><title type='text'>Classic 25 Horse Problem</title><content type='html'>&lt;span class="Apple-style-span" style="color: #565e67; font-family: Verdana, 'Times New Roman', serif; font-size: 12px;"&gt;Classic 25 horse problem,&lt;br /&gt;25 Horses,&lt;br /&gt;Have a 5 horse track,&lt;br /&gt;No stopwatch,&lt;br /&gt;How many races are required to determine the 3 fastest horses?&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: #565e67; font-family: Verdana, 'Times New Roman', serif; font-size: 12px;"&gt;Answer : 7 Races&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: #565e67; font-family: Verdana, 'Times New Roman', serif; font-size: 12px;"&gt;And here goes why?&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;&lt;span class="Apple-style-span" style="color: #565e67; font-family: Verdana, 'Times New Roman', serif; font-size: 12px;"&gt;we have 5 races for 25 horses that 5 horses on a team, define each team as a, b, c, d, e.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span class="Apple-style-span" style="color: #565e67; font-family: Verdana, 'Times New Roman', serif; font-size: 12px;"&gt;carry a best horse race for each team first place, define them as a.1,b.1,c.1,d.1,e.1&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span class="Apple-style-span" style="color: #565e67; font-family: Verdana, 'Times New Roman', serif; font-size: 12px;"&gt;assume prior best horse race 's top 3 places are a.1 b.1 c.1 , so we know the fastest horse is a.1&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span class="Apple-style-span" style="color: #565e67; font-family: Verdana, 'Times New Roman', serif; font-size: 12px;"&gt;we only need to take last race to know who are second and third quickest horse.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span class="Apple-style-span" style="color: #565e67; font-family: Verdana, 'Times New Roman', serif; font-size: 12px;"&gt;The horses that participate in this race are b.1 b.2 a.2 a.3 c.1 , this race 's top 2 places are 2nd and 3rd quickest horses&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: #565e67; font-family: Verdana, 'Times New Roman', serif; font-size: 12px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-3947044345855924184?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/3947044345855924184/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/classic-25-horse-problem.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3947044345855924184'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/3947044345855924184'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/classic-25-horse-problem.html' title='Classic 25 Horse Problem'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-1412733175009358000</id><published>2010-05-11T07:05:00.000-07:00</published><updated>2010-07-17T07:48:44.153-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><category scheme='http://www.blogger.com/atom/ns#' term='arrays'/><title type='text'>Search two numbers from array to make a sum</title><content type='html'>&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;You have a array of random numbers and you are given a number k. Find the 2 elements in the array which sum up to k. &lt;/div&gt;&lt;div style="text-align: justify;"&gt;e.g: If my array is {2,5,3,1,8,7,5,4} and k=6.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;Then 2 numbers that sum up to 6 are 5 and 1.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;step 1: sort the array //O(n.log(n))&lt;/div&gt;&lt;div style="text-align: justify;"&gt;arr=2,5,3,1,8,7,5,4 --&amp;gt; 1,2,3,4,5,5,7,8&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;//size=8&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;step 2:&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;i=0, j=7&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;if a[i]+a[j]==K //done&lt;/div&gt;&lt;div style="text-align: justify;"&gt;if a[i]+a[j] &amp;gt; K //j--&lt;/div&gt;&lt;div style="text-align: justify;"&gt;if a[i]+a[j] &amp;lt; K //i++&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;repeat step2, till it reaches mid point //O(n)&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-1412733175009358000?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/1412733175009358000/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/search-two-numbers-from-array-to-make.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1412733175009358000'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/1412733175009358000'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/search-two-numbers-from-array-to-make.html' title='Search two numbers from array to make a sum'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-2720521121127330385</id><published>2010-05-11T06:56:00.000-07:00</published><updated>2010-07-17T07:49:05.755-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='puzzle'/><title type='text'>Probability</title><content type='html'>&lt;div style="text-align: justify;"&gt;Probability question: Persons A and B go shopping together. Say person A spent X amount of money and B Y. What is the probability that the sum total of their purchases [i.e. X+Y] has 0 cents [i.e. is a whole number]. ?&lt;/div&gt;&lt;br /&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;Answer : &lt;/strong&gt;The person A can have cents in the range of 0 to 99, and same with the case B. Thus they have 100 cases each, and total number of cases is 100x100. Out of them the cases of our interest is (0, 0) (1,99), (2, 98), (3, 97) ... (99. 1) is 100. So the probability is 100/10000 = 1/100.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-2720521121127330385?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/2720521121127330385/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/probability.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2720521121127330385'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/2720521121127330385'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/probability.html' title='Probability'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-4725263485326594995</id><published>2010-05-11T04:12:00.000-07:00</published><updated>2010-07-17T07:49:05.755-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='puzzle'/><title type='text'>Count 45 minutes using rope</title><content type='html'>&lt;div style="text-align: justify;"&gt;Given 2 non-uniform ropes (each burns down in 1hr, but not uniformly), how to measure 45 mins?&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;Answer :&lt;/strong&gt; Take one rope connect both ends. Ignite the connection point and one end of the other rope at the same time. When the looped rope burns out, it is 30 mins. Then ignite the unburned end of the remaining rope. When the remaining rope burns out, it is another 15 mins. So it is 45 mins.&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-4725263485326594995?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/4725263485326594995/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/count-45-minutes-using-rope.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4725263485326594995'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4725263485326594995'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/count-45-minutes-using-rope.html' title='Count 45 minutes using rope'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-5410156976697380164</id><published>2010-05-11T04:09:00.000-07:00</published><updated>2010-07-17T07:49:05.756-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='puzzle'/><title type='text'>Three Orange Boxes</title><content type='html'>&lt;div style="text-align: justify;"&gt;Three boxes, one with apples, one with oranges, one with a mix of apples and oranges, all the boxes are labeled incorrectly, you can pick up just one fruit.&amp;nbsp;How do you&amp;nbsp;tell which box has what fruit?&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;strong&gt;Answer &lt;/strong&gt;: All the labels are incorrect, so pick a fruit from the box labeled&amp;nbsp;mixed box. That will tell you if its the apple or orange box, because its not mixed. The other labels are also incorrect, so the box labeled with the fruit you picked will be the box containing just the other type of fruit. The remaining one will be the mixed box.The second box cant be mixed fruit box because then the third box will be labelled correct which is not the case&amp;nbsp;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-5410156976697380164?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/5410156976697380164/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/three-orange-boxes.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5410156976697380164'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/5410156976697380164'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/three-orange-boxes.html' title='Three Orange Boxes'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-8212814969195144560</id><published>2010-05-10T23:37:00.001-07:00</published><updated>2010-07-17T07:48:16.503-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>where is volatile variables stored in memory layout ?</title><content type='html'>&lt;div align="justify"&gt;The storage of a variable is not decided based on if it is volatile or not. It can be anywhere as is the case with normal variable. So the variable may be on stack,heap or in the data section of executable, depending on how it gets defined. The volatile qualifier just tells the compiler that this variable may change in ways that are not apparent to you, it can be changed at any point of time, for example is hardware registers (variables mapped to h/w registers). So compiler disables any optimizations such as caching on this variable.&lt;br /&gt;&lt;br /&gt;Volatile is type qualifier not a storage class specifier. &lt;/div&gt;&lt;div align="justify"&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-8212814969195144560?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/8212814969195144560/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/where-is-volatile-variables-stored-in.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8212814969195144560'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8212814969195144560'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/where-is-volatile-variables-stored-in.html' title='where is volatile variables stored in memory layout ?'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-8947502799257331347</id><published>2010-05-10T23:27:00.001-07:00</published><updated>2010-07-17T07:48:16.503-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>Find binary of a Number</title><content type='html'>Write a function to print the binary value of the number passed to it, and function should not use any variables other than the parameter passed to it.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Answer :&lt;/strong&gt; We need to use recursion for this, and here is my version of the C code for the same&lt;br /&gt;&lt;pre style="BORDER-BOTTOM: #999999 1px dashed; BORDER-LEFT: #999999 1px dashed; PADDING-BOTTOM: 5px; LINE-HEIGHT: 14px; BACKGROUND-COLOR: #eee; PADDING-LEFT: 5px; WIDTH: 100%; PADDING-RIGHT: 5px; FONT-FAMILY: Andale Mono, Lucida Console, Monaco, fixed, monospace; COLOR: #000000; FONT-SIZE: 12px; OVERFLOW: auto; BORDER-TOP: #999999 1px dashed; BORDER-RIGHT: #999999 1px dashed; PADDING-TOP: 5px"&gt;&lt;code&gt;#include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;&lt;br /&gt;void printBinary(int k)&lt;br /&gt;{&lt;br /&gt;    if(k != 0)&lt;br /&gt;    {&lt;br /&gt;        printBinary(k/2);&lt;br /&gt;    }&lt;br /&gt;    printf("%d", k%2);&lt;br /&gt;}&lt;br /&gt;void main(void)&lt;br /&gt;{&lt;br /&gt;    int k = 4561;&lt;br /&gt;    printBinary(k);&lt;br /&gt;}&lt;/code&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-8947502799257331347?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/8947502799257331347/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/find-binary-of-number.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8947502799257331347'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8947502799257331347'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/find-binary-of-number.html' title='Find binary of a Number'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-8980352412786473773</id><published>2010-05-10T20:32:00.000-07:00</published><updated>2010-05-10T20:34:35.515-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='puzzle'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><category scheme='http://www.blogger.com/atom/ns#' term='arrays'/><title type='text'>Array manuplation</title><content type='html'>Given a array of random integers, sort the odd elements in descending order and even numbers in ascending order. Optimize for time complexity. &lt;br /&gt;e.g. for i/p (1,4,5,2,3,6,7) O/p = (7,5,3,1,2,4,6)&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Answer :&lt;/strong&gt;&lt;br /&gt;We can solve this by doing a simple bubble sort, with the below logic&lt;br /&gt;&lt;ol&gt;&lt;li&gt;if first number and second number are odd &amp;gt;&amp;gt; compare and exchange &amp;gt;&amp;gt; push lower odd to first&lt;/li&gt;&lt;li&gt;if first is odd and second is even &amp;gt;&amp;gt; no exchange&amp;nbsp;&amp;gt;&amp;gt; we want odd in the first&lt;/li&gt;&lt;li&gt;if first is even and second is also even &amp;gt;&amp;gt; compare and exhange&amp;nbsp;&amp;gt;&amp;gt; push higher even number to last&lt;/li&gt;&lt;li&gt;if first is even and second is odd &amp;gt;&amp;gt; always exchange&amp;nbsp;&amp;gt;&amp;gt; since we want odd numbers first&lt;/li&gt;&lt;/ol&gt;Here is the complete solution in C&lt;br /&gt;&lt;pre style="background-color: #eeeeee; border-bottom: #999999 1px dashed; border-left: #999999 1px dashed; border-right: #999999 1px dashed; border-top: #999999 1px dashed; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding-bottom: 5px; padding-left: 5px; padding-right: 5px; padding-top: 5px; width: 100%;"&gt;&lt;code&gt;#include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;&lt;br /&gt;int a[] = {1,4,5,2,3,6,7};&lt;br /&gt;int len = 7;&lt;br /&gt;&lt;br /&gt;void main(void)&lt;br /&gt;{&lt;br /&gt;    int i,j, temp;&lt;br /&gt;    for(i = 0; i &amp;lt; len-1; i++)&lt;br /&gt;    {&lt;br /&gt;        for(j = 0; j&amp;lt; len-1; j++)&lt;br /&gt;        {&lt;br /&gt;         if( a[j] %2  != 0) &lt;br /&gt;         {     // first odd number&lt;br /&gt;             if(a[j+1] % 2 != 0) &lt;br /&gt;             {   &lt;br /&gt;                 // second odd number&lt;br /&gt;                 if(a[j] &amp;lt; a[j+1]) &lt;br /&gt;                 {&lt;br /&gt;                     temp = a[j+1];&lt;br /&gt;                     a[j+1] = a[j];&lt;br /&gt;                     a[j] = temp;&lt;br /&gt;                 }&lt;br /&gt;             }&lt;br /&gt;             else &lt;br /&gt;             {     // second even number &lt;br /&gt;                 //do nothing&lt;br /&gt;             }&lt;br /&gt;         }&lt;br /&gt;         else &lt;br /&gt;         {     // first even number&lt;br /&gt;             if(a[j+1] % 2 != 0) &lt;br /&gt;             {   &lt;br /&gt;                 // second odd number&lt;br /&gt;                 // always interchange&lt;br /&gt;                 temp = a[j+1];&lt;br /&gt;                 a[j+1] = a[j];&lt;br /&gt;                 a[j] = temp;&lt;br /&gt;             }&lt;br /&gt;             else&lt;br /&gt;             {&lt;br /&gt;                 // second even number&lt;br /&gt;                 if(a[j] &amp;gt; a[j+1])&lt;br /&gt;                 {&lt;br /&gt;                     temp = a[j+1];&lt;br /&gt;                     a[j+1] = a[j];&lt;br /&gt;                     a[j] = temp;&lt;br /&gt;                 }&lt;br /&gt;             }&lt;br /&gt;         }&lt;br /&gt;        }&lt;br /&gt;    }&lt;br /&gt;    for(i=0; i&amp;lt;len; i++)&lt;br /&gt;    printf("%d ", a[i]);&lt;br /&gt;}&lt;/code&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-8980352412786473773?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/8980352412786473773/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/array-manuplation.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8980352412786473773'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/8980352412786473773'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/array-manuplation.html' title='Array manuplation'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-4958275690619680947</id><published>2010-05-10T02:39:00.001-07:00</published><updated>2010-05-10T02:43:43.293-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='puzzle'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><title type='text'>Find the Odd ball</title><content type='html'>&lt;div align="justify"&gt;You are given 80 balls and out of which only 1 has more weight than other 79. also, you are given weighing machine which can weigh any number of balls of 2 sets( 40 40 or 25 25 etc) at one time &lt;/div&gt;&lt;div align="justify"&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;&lt;strong&gt;Answer:&lt;/strong&gt;&lt;br /&gt;Assume the ball we need to find is X. Divide into 3 groups, A (27 balls), B (27 balls), C (26 balls)&lt;br /&gt;&lt;br /&gt;Step 1: Weight A vs B, whichever is heavier has X. If equal, then C has X. If C has X, choose a random ball in A and put into C so that C has 27 balls.&lt;br /&gt;&lt;br /&gt;Step 2: After step 1, we determine which group has X, and the group size is 27. Divide into 3 smaller groups, each of size 9, and repeat the same procedure.&lt;br /&gt;&lt;br /&gt;In short, we have, 80 -&gt; 27 -&gt; 9 -&gt; 3 -&gt; 1, 4 steps in total to find X.&lt;br /&gt;&lt;br /&gt;In general , if there are n balls , log_3(n) is the answer, or find out how many powers 3 should be raised to cross the total number of balls &lt;/div&gt;&lt;div align="justify"&gt;&lt;/div&gt;&lt;/br&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-4958275690619680947?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/4958275690619680947/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/find-odd-ball.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4958275690619680947'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/4958275690619680947'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/find-odd-ball.html' title='Find the Odd ball'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-7372483851500728489</id><published>2010-05-10T02:23:00.000-07:00</published><updated>2010-05-10T02:26:47.846-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='strings'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>Sub Strings</title><content type='html'>&lt;div align="justify"&gt;write a code for which input is a string and set of characters acting as delimiters. Cut the given string where ever delimiters occur and return all the set of sub strings. For eg: given string abbcdeffghujsb and delimiter set:c,g,j hen output should be: abb, deff, u, sb &lt;/div&gt;&lt;div align="justify"&gt;&lt;/div&gt;&lt;strong&gt;Answer goes as below&lt;/strong&gt;&lt;br /&gt;&lt;pre style="BORDER-BOTTOM: #999999 1px dashed; BORDER-LEFT: #999999 1px dashed; PADDING-BOTTOM: 5px; LINE-HEIGHT: 14px; BACKGROUND-COLOR: #eee; PADDING-LEFT: 5px; WIDTH: 100%; PADDING-RIGHT: 5px; FONT-FAMILY: Andale Mono, Lucida Console, Monaco, fixed, monospace; COLOR: #000000; FONT-SIZE: 12px; OVERFLOW: auto; BORDER-TOP: #999999 1px dashed; BORDER-RIGHT: #999999 1px dashed; PADDING-TOP: 5px"&gt;&lt;code&gt;char delimiter[] = {'c', 'j' , 'f'};&lt;br /&gt;&lt;br /&gt;void get_sub_str(const char *str, char *dl, int dn)&lt;br /&gt;{&lt;br /&gt;    char temp[1024];&lt;br /&gt;    int i, j, len = 0;&lt;br /&gt;    int ssu = 0; // sub string update&lt;br /&gt;    for(i=0; str[i]!='\0'; i++)&lt;br /&gt;    {&lt;br /&gt;       for(j=0; j&amp;lt;dn; j++)&lt;br /&gt;       {&lt;br /&gt;           if( str[i] == dl[j])&lt;br /&gt;               ssu = 1;&lt;br /&gt;       }&lt;br /&gt;       if(ssu == 1)&lt;br /&gt;       {&lt;br /&gt;           temp[len] = '\0';&lt;br /&gt;           printf("%s\n", temp);&lt;br /&gt;           len = 0;&lt;br /&gt;           ssu = 0;&lt;br /&gt;           i++;&lt;br /&gt;       }&lt;br /&gt;       temp[len] = str[i];&lt;br /&gt;       len++;&lt;br /&gt;    }&lt;br /&gt;}&lt;/code&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-7372483851500728489?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/7372483851500728489/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/sub-strings.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7372483851500728489'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7372483851500728489'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/sub-strings.html' title='Sub Strings'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-7827746749226733897</id><published>2010-05-10T02:16:00.000-07:00</published><updated>2010-05-10T02:22:15.636-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>Signed and Unsigned</title><content type='html'>1. What is the output of the following program&lt;br /&gt;&lt;pre style="BORDER-BOTTOM: #999999 1px dashed; BORDER-LEFT: #999999 1px dashed; PADDING-BOTTOM: 5px; LINE-HEIGHT: 14px; BACKGROUND-COLOR: #eee; PADDING-LEFT: 5px; WIDTH: 100%; PADDING-RIGHT: 5px; FONT-FAMILY: Andale Mono, Lucida Console, Monaco, fixed, monospace; COLOR: #000000; FONT-SIZE: 12px; OVERFLOW: auto; BORDER-TOP: #999999 1px dashed; BORDER-RIGHT: #999999 1px dashed; PADDING-TOP: 5px"&gt;&lt;code&gt;main() {&lt;br /&gt;    unsigned int a = 10;&lt;br /&gt;    int b = -19;&lt;br /&gt;    puts((a+b)&amp;gt;0? "Positive":"Negative");&lt;br /&gt;}&lt;/code&gt;&lt;/pre&gt;&lt;p align="justify"&gt;&lt;strong&gt;Answer :&lt;/strong&gt; Positive&lt;br /&gt;&lt;strong&gt;Explanation :&lt;/strong&gt; When signed and unsigned arithmetic is done, signed is converted to unsigned and result will be unsigned, ANSI C standard.&lt;/p&gt;&lt;p align="justify"&gt; &lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6068884217450514184-7827746749226733897?l=technology-shettyprasad.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://technology-shettyprasad.blogspot.com/feeds/7827746749226733897/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/signed-and-unsigned.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7827746749226733897'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6068884217450514184/posts/default/7827746749226733897'/><link rel='alternate' type='text/html' href='http://technology-shettyprasad.blogspot.com/2010/05/signed-and-unsigned.html' title='Signed and Unsigned'/><author><name>Prasad Shetty</name><uri>http://www.blogger.com/profile/09951999212690576646</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='20' height='32' src='http://2.bp.blogspot.com/-pAzO51lmiko/TrOohVpf9eI/AAAAAAAAHIY/i0vOFKamRrQ/s220/2011-08-28.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6068884217450514184.post-5557184714498383717</id><published>2010-05-09T02:23:00.000-07:00</published><updated>2010-05-10T02:16:49.131-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='c++'/><category scheme='http://www.blogger.com/atom/ns#' term='linked list'/><category scheme='http://www.blogger.com/atom/ns#' term='interview'/><category scheme='http://www.blogger.com/atom/ns#' term='c'/><title type='text'>Linked List Example</title><content type='html'>&lt;div align="justify"&gt;Recently I was recalling my linked list concepts, and I found that I know the concepts, but when programming I am missing something. So I thought I should do it once again, so I made a simple program, which can add / delete elements from linked list. here it is for your reference. &lt;/div&gt;&lt;div align="justify"&gt;&lt;br /&gt;shetty.h, this file contains the basic type definitions required. &lt;/div&gt;&lt;pre style="BORDER-BOTTOM: #999999 1px dashed; BORDER-LEFT: #999999 1px dashed; PADDING-BOTTOM: 5px; LINE-HEIGHT: 14px; BACKGROUND-COLOR: #eee; PADDING-LEFT: 5px; WIDTH: 100%; PADDING-RIGHT: 5px; FONT-FAMILY: Andale Mono, Lucida Console, Monaco, fixed, monospace; COLOR: #000000; FONT-SIZE: 12px; OVERFLOW: auto; BORDER-TOP: #999999 1px dashed; BORDER-RIGHT: #999999 1px dashed; PADDING-TOP: 5px"&gt;&lt;code&gt;#ifndef __SHETTY_H_&lt;br /&gt;#define __SHETTY_H_&lt;br /&gt;&lt;br /&gt;typedef struct le {&lt;br /&gt;    int ld;&lt;br /&gt;    le *next;&lt;br /&gt;} le;&lt;br /&gt;&lt;br /&gt;typedef struct lh {&lt;br /&gt;    le *next;&lt;br /&gt;} lh;&lt;br /&gt;&lt;br /&gt;#endif // __SHETTY_H_&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p align="justify"&gt;Shetty.cpp, this file contains all the functionality required to add or delete from the linked list. The comments are self explanatory.&lt;br /&gt;&lt;/p&gt;&lt;pre style="BORDER-BOTTOM: #999999 1px dashed; BORDER-LEFT: #999999 1px dashed; PADDING-BOTTOM: 5px; LINE-HEIGHT: 14px; BACKGROUND-COLOR: #eee; PADDING-LEFT: 5px; WIDTH: 100%; PADDING-RIGHT: 5px; FONT-FAMILY: Andale Mono, Lucida Console, Monaco, fixed, monospace; COLOR: #000000; FONT-SIZE: 12px; OVERFLOW: auto; BORDER-TOP: #999999 1px dashed; BORDER-RIGHT: #999999 1px dashed; PADDING-TOP: 5px"&gt;&lt;code&gt;#include "shetty.h"&lt;br /&gt;#include "malloc.h"&lt;br /&gt;#include "stdio.h"&lt;br /&gt;&lt;br /&gt;lh list;&lt;br /&gt;&lt;br /&gt;/********************************************&lt;br /&gt;** This function adds an element to Linked&lt;br /&gt;** list, the head to list and element to be&lt;br /&gt;** added is given as params.&lt;br /&gt;** lst - pointer to the head of the list&lt;br /&gt;** ld  - an integer data, u can change this&lt;br /&gt;**       to whatever type you want to.&lt;br /&gt;********************************************/&lt;br /&gt;void add_list(lh *lst, int ld)&lt;br /&gt;{&lt;br /&gt;    le *element;&lt;br /&gt;    le **tmp;&lt;br /&gt;    element = (le *) malloc (sizeof(*element));&lt;br /&gt;    element-&amp;gt;ld = ld;&lt;br /&gt;    element-&amp;gt;next = NULL;&lt;br /&gt;&lt;br /&gt;    tmp = &amp;amp;(lst-&amp;gt;next);&lt;br /&gt;    while(*tmp!=NULL)&lt;br /&gt;        tmp = &amp;amp;((*tmp)-&amp;gt;next);&lt;br /&gt;    *tmp = element;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;/********************************************&lt;br /&gt;** This function removes an element from the&lt;br /&gt;** Linked list&lt;br /&gt;********************************************/&lt;br /&gt;void remove_list(lh *lst, int ld)&lt;br /&gt;{&lt;br /&gt;    le **tmp, **prev;&lt;br /&gt;    le *deleted;&lt;br /&gt;&lt;br /&gt;    tmp = &amp;amp;(lst-&amp;gt;next);&lt;br /&gt;    prev = tmp;&lt;br /&gt;    while(*tmp!=NULL)&lt;br /&gt;    {&lt;br /&gt;        if((*tmp)-&amp;gt;ld == ld)&lt;br /&gt;        {&lt;br /&gt;            deleted  = (*prev)-&amp;gt;next;      &lt;br /&gt;            (*prev)-&amp;gt;next = (*tmp)-&amp;gt;next;&lt;br /&gt;            free(deleted);                  &lt;br /&gt;        }&lt;br /&gt;            prev = tmp;&lt;br /&gt;            tmp = &amp;amp;((*tmp)-&amp;gt;next);&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;/**************************************&lt;br /&gt;** Display the list to see elements&lt;br /&gt;**************************************/&lt;br /&gt;void disp_list(lh *lst)&lt;br /&gt;{&lt;br /&gt;    le **tmp;&lt;br /&gt;    tmp = &amp;amp;(lst-&amp;gt;next);&lt;br /&gt;    while(*tmp!=NULL)&lt;br /&gt;    {&lt;br /&gt;        printf("%d\t", (*tmp)-&amp;gt;ld);&lt;br /&gt;        tmp = &amp;amp;((*tmp)-&amp;gt;next);&lt;br /&gt;    }&lt;br /&gt;    printf("\n");&lt;br /&gt;}&lt;br /&gt;int main(void)&lt;br /&gt;{&lt;br /&gt;    list.next = NULL;&lt;br /&gt;    add_list(&amp;amp;list, 25);&lt;br /&gt;    add_list(&amp;amp;list, 30);&lt;br /&gt;    disp_list(&amp;amp;list);&lt;br /&gt;    add_list(&amp;amp;list, 45);&lt;br /&gt;    disp_list(&amp;amp;list);&lt;br /&gt;    add_list(&amp;amp;list, 55);&lt;br /&gt;    disp_list(&amp;amp;list);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p align="justify"&gt;Here, only one thing is important in dealing with linked list. i.e we need to get the address of the next pointer in a temp variable, and then change this variable with different address as we traverse the list. We should not modify any of the pointers in the list while traversing, unless we want to add or delete from the list.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='htt
