Upvotes on Questions, Answers, Comments, etc

Question: Might just be me, but why does it seem like no one is voting on questions and answers on Linguistics.SE - I'd run some queries to attempt to prove this, but beta sites are not listed on the Data.SE site.
Comment: I agree with @blunders - compared with other Stack Exchange sites I've used there is a lot less voting and also accepting of answers on this site. I noticed it weeks ago in fact.
Comment: what do you mean? The questions and answers are getting upvotes
Answer: I vote -- though I'll admit I vote more on answers than on questions.
I've been assuming that an upvote on a question means something like "Oh hey I was wondering the same thing!"  (I'm not terribly familiar with SE outside of this subsite.)  When else would upvoting a question be appropriate?
Comment: Voting up a question can mean "This question is welcome on this site" or "This is a reasonably formulated on-topic question". Basically, voting is for encouraging welcome behaviour, so why be stingy when you want more questions on this site?
Comment: @blunders down-voting a question is free as well. Down-voting an answer is not. If you want to know what the up-votes and down-votes literally mean, put the mouse over the "arrows", you'll get a quick explanation, although you can vote for other reasons too, of course.
Comment: Re: Comments Upvoting... One thing I did see, which I find interesting is that the rollover text is phrased different between the **questions** (shows research effort; useful and clear), **answers** (useful), and **comments** (great). Using the word "great" seems off or subjective to me, seems like it should be "useful" too; but that's just my opinion.
Comment: One last point, voting is free, there's no cost to voting, and if done correctly ever single vote adds value to the site. On the other hand, downvoting is a bad habit to get in, and cost rep points.
Comment: +1 Alenanno: Interesting, learn something new every day, here's the SE reference to what you're talking about: [FAQ-Reputation](http://linguistics.stackexchange.com/faq#reputation)
Comment: Consider those as rough guidelines... Obviously you can up-vote a comment also if it's "useful" and not just "great". :)
Comment: +1 @Dan Velleman: Makes sense, though at this point it's unclear what is a "good" question - but that's a completely different question.
Comment: so here's an example of what I mean, you [agreed with Joe's comment here](http://linguistics.stackexchange.com/questions/810/languages-dialects/812#812), but did not up vote it. It's very important based on my understanding to vote as often as possible. While this very well not be a pattern, it is an example of what I'm talking about in general; voting patterns are hard to see, but it still "seems" like there's a pattern to me.
Comment: Interesting.  I'm used to the way Metafilter handles this stuff, where nobody would bat an eye if I commented to say "I agree with so-and-so" but didn't give so-and-so's comment a "favorite" (which is what they use instead of upvotes).  Is that a faux pas here?
Comment: ...in fact, I went to upvote Joe's comment there and found that I couldn't.  So I'm wondering if something else is up.
Comment: In my opinion, it doesn't matter what is the norm on Metafilter or SE (hahaha)... point is if someone mainly most comments (and not questions and answers) and people agree with them, but never upvote them, they will not get a rep on the site. Votes are the core of filtering content on SE.
Comment: As for not being able to upvote a comment, only thing I'm able to think of is you're weren't logged in (unlikely, but possible) or you should try refreshing the page; which has done the trick for me in the past.
Comment: Right, the reload helped.  Never mind.
Answer:
on stackexchange, you can vote up or down on questions and just up on comments.
Rep is calculated using rules to encourage certian kinds of voting:

voting down on anything is -1 pt for you the voter (upvoting is better in comparison, and it discourages retaliatory voting).
voting is free for questions -and- answers (both are encouraged).
a voting greater than 1 to 4 ratio questions to answers for 600 votes on questions, is encouraged by a gold badge, Electorate.

SE sites only get a place on data.SE only if they are out of beta.
sometimes there are weird fluctuations in question or answer quality or just traffic altogether. Or people might be losing interest.


Show unlimited text field in document Info panel but not in the document library?

Question: In a Sharepoint 2010 doc library, we would like to allow users the convenience of being able to enter large amounts of doc-specific text via the document Info 'data entry' panel, but NOT show all that text in the doc lib view...just show a "view details" link , so that IF a user wants to read a particular document's doc-specific text, he can click on the link and have the text pop up. Is there a practical way to achieve this?  (Advice greatly appreciated!)
Answer: You should go for a custom field which inherits from SPFieldText. Nothing special should be changed in control class or field class. just change the field definition xml. Check for the tag <RenderPattern Name="DisplayPattern"> element in field definition xml. There is this reference in msdn, but you can google for more. Also you can take a look at 14\TEMPLATE\XML\FLDTYPES.XML for SharePoint built-in fields to get some clue about field definition xml and more specifically, RenderPatterns.
You can create a simple html  or even <button> in display pattern to be shown in list views and configure it to run some ajax code to retrieve field value (Or even much simpler, you can use SharePoint Client object model to retrieve field value in javascript). I have done this before in SharePoint 2007 it is possible.


Is ginger soluble In water, fat or both?

Question: Is ginger soluble/can it creates strong flavours in water, fat or both together?
Answer: No, by strict interpretation of your question, ginger itself is a plant. Plants are typically insoluble as they are composed of chemicals that are fat and water insoluble to a greater or lesser extent.
However, the major spice component in ginger is [6]-gingerol, this is a volatile ketone that is soluble in a range of organic solvents (oils/fats seem likely), but only very barely soluble in water. There are a range of other flavour/scent compounds found in ginger, some of which will be water soluble, some will be organic solvent soluble, that play a role in the taste of ginger, but these are too abundant to go into.
Note that water or fat solubility has only a partial influence on your ability to taste the ginger. You can make tea from ginger and taste and feel very strongly the gingerol, but this is because the gingerol is forming a fine layer of oil on the surface of the water and you can taste minute amounts of it. In addition, it scores 60,000 on the Scoville scale - similar in range to a cayenne pepper and much hotter than a jalapeno, so in a tea with nothing to cushion the effect, the heat is very obvious.
Comment: the only ginger I'd chew by choice is candied or in syrup. I was meaning more consuming it in a sauce (or soup; I make a split pea and ginger soup that's far better with fresh, using a bit of dried if more is needed towards the end). Anyway, you're right of course
Comment: To confirm by experiment: Honey+lemon+ginger in hot water is quite soothing for common cold; the ginger flavour comes out, but a sludge forms in the bottom of the mug.  If everything is clean and rinsed, you can actually see the oils come to the surface when you pour water onto dried ginger. The flavour you get from ginger depends on what you do (as well as presence/absence of sugar), so while it's possible to get a strong flavour steeping it in water and straining, it's not the same strong flavour as if you consumed it (not sure if this is just the solubility to mention)
Comment: @ChrisH the change in flavour steeping cf. chewing will be a mix of things. Steeping works best with powder or dried flakes, which will have lost some of the volatiles already, whereas you are more likely to chew fresh, which makes a mush with greater contact with tongue and captures all/most of the volatile compounds in the airway. You could try chewing fresh vs dry and see if the difference is noticeable, but I doubt it will be pleasant. Solvent extraction is the other part of it - water isn't a good solvent for oils, but the fats in your mouth are.


Bypass ac compressor with smaller belt

Question: My ac compressor is shreding bits of metal.I think the bearings in the pulley is bad. Can i bypass it by buying a smaller belt and bypassing the ac pulley?
Comment: Yes you can. Just unplug the wires which energize the clutch. Should be two wires (power & ground). This shouldn't cause you any issues. In actuality, you probably wouldn't need to unplug it at all since even it it energizes, it's not going to do anything without a belt on it.
Comment: Long-term lack of circulating freon may cause some issues within the system - seals can dry out, etc.  Just beware that you may be condemning other parts of the AC system to an early death.
Comment: Knowing the Make, Model, Year and engine size would be helpful.
Comment: Also i dont know if i need to unplug the ac compressor because i will still need to use the defroster and it makes the compressor turn on
Comment: @mike65535 The compressor's shaft seal can perish, o-rings can perish and the dryer and system oil charge might need replacement.
Answer: Yes you can, and this is definitely possible on some models of car (I know for sure that that can be done on my car and it is a belt from a Renault - can't remember which model).
You need to find the length of belt necessary, so take a piece of string and wrap it around all the pulleys, make sure the adjuster or tensioner pulley is in the compressed position and you will have the minimum length of belt required.
After that all you need to do is find a matching belt - some places are very helpful, others less so...

Bypass ac compressor with smaller belt


SharePoint Page Creation using custom Content type is not working

Question: i have created a Application page in pages library,and i have selected my content type then choosed a custom page layout .And i clicked to create a page ,its taking time to load and i m getting error like"This page is not using a valid page layout. To correct the problem, edit page settings and select a valid page layout."
"
Any one faced this issue?
Answer: There are two potential resolutions for this.
If the page was working at some point in time, use Version History to revert to the last known working version:

Go to Site Actions -> View All Site Content.
Click Pages.
Click the dropdown menu next to the .aspx page in question.
Select Version History.
Preview older versions to see if the issue was recently introduced. If possible, identify a last-known working version, and suggest the customer restore that version.

Alternatively, we can try to manually try to fix the page layout:
You may find in Site Content and Structure (/_layouts/sitemanager.aspx) that the Page Layout is listed by path, as opposed to by name. For example, the layout is listed as "/_catalogs/masterpage/WelcomeLinks.aspx" instead of "Welcome page with summary links".
First, we will want to ensure the template is enabled in /_layouts/AreaTemplateSettings.aspx. Typically, Page Layouts is set to "Pages in this site can use any layout".
Then we will want to go to View All Site Content (/_layouts/viewlsts.aspx) -> Pages, click the dropdown on the affected page and select "Edit page properties". From here, select a valid layout. You should now be able to render the page.
We sometimes have force the page layout to reset, by changing it to something else, then back to the original layout in both viewlsts.aspx and sitemanager.aspx:

Go to /_layouts/viewlsts.aspx -> Pages -> Edit page properties of the
affected page and change the layout to something else.
Go to /_layouts/sitemanager.aspx -> Pages -> Edit page settings of
the affected page and change the layout to the same as Step 1.
Go back to viewlsts.aspx and change the layout to the original.
Go back to sitemanager.aspx and change the layout back to the original.
Confirm the layout in sitemanager.aspx now displays by Name, not path.
Confirm the page no longer throws errors.

Reference: Microsoft Knowledge base Article


Word 2016: Using StyleRef for Heading #s in Header differently

Question: I have a document that requires the heading to contain the item number (level 3 heading) that is being continued onto that page from the previous page. Using the Field insert and StyleRef, I can make the heading show either the item that appears first or last on that page- but I can't make it reference the page before. Could a little bit of VBA do the trick? Anyone had to do this before?
Comment: Done as requested.
Comment: See this posted [example document](https://onedrive.live.com/view.aspx?resid=4DE3A20A33EEA203!1284&app=Word) for a solution, entailing a rather painful use of SEQ fields.
Comment: Wow, @harrymc, that is phenomenal. Thank you. And you are right about painful. I'm guessing this would be a horrid idea in a super large document just based on resource usage alone, much less the tricks required to update. But it gives me something to think about - mostly, that we will probably continue to skirt this insane requirement as best we can. I'm thinking you deserve the bounty just from this sample.
Answer: I have found this
posted example document
as a solution, entailing a rather painful use of SEQ fields.
The document contains its own documentation with examples. It says:

This document shows one way that you can use field codes in Word to
  display simple messages along the lines of "Section N continued from
  previous page" and "…Section N continues on next page" in the document
  footer and header, as required, where "N" is a section number. In this
  example, we are getting the Section numbers from the heading numbering
  of Heading 1 paragraphs. There are other possibilities.
This approach was constructed from an earlier attempt to do Table
  continuations, and could probably be simplified in various ways.
As it stands, the approach requires

continuous page numbering – it might work in some section-page numbering scenarios, but probably only by accident. Dealing with two
  or more numbering schemes per document using field codes alone is not
  trivial, and may not even be possible.
users who understand how to use field codes, and understand how this particular solution works. In this case, in addition to having an
  understanding of how field codes work in general, they will also need
  to ensure that each "section" starts with a certain set of field
  codes, and each "section" also needs to end with a certain set of
  field codes.


Can I have unregistered guests at my hotel room?

Question: I'll be staying in Paris for several weeks and I am planning to stay at an Ibis hotel. I want to know if I am able to invite unregistered guests during the day (not to sleep, eat, or take advantage of any other service). Or if I have to pay a fee.
Answer: Yes, Some hotels will allow unregistered guests at your hotel room, while some hotels can give you a fine due to unregistered guests to come at a certain time, or too many unregistered guests.


Django signals as IPC

Question: So I have written a websocket application in Twisted.  The application is a basic game between a number of users, but trying to use the web socket for setup and record saving is painful, so I was looking into using Django based rendering for the supplementary information (as in standings, game setup, lobby list, etc) and leave the websockets for the real action.  I know I can use some basic IPC functionality to have the Django requests signal the Twisted application, but I was curious if the Django signal system would also work across applications as a simple form of IPC...
Answer: No. Django signals are restricted to a single Python interpreter. You'll need to put together something else (sockets, JSON-RPC, XMPP, etc.) in order to perform IPC.

Django signals as IPC


not clear glass how do I fix is it hacked?

Question: i have a picture in my blender glass how do I fix? Is it hacked?
Comment: It is clear. You can see the world through it. Check out the rendered view (press Z > Rendered)
Answer: By default the Material Preview mode will use a default HDRI (world image) and that's what is reflected on your object. To change that you can go into the Viewport Shading panel and check Scene World for example:
Answer: Since you are a totally beginner to Blender maybe you should watch some basic tutorials.
What you see is just a special kind of shading mode which you have chosen here

Just tap on another button and you see another kind of viewport shading mode.
More information here:
https://docs.blender.org/manual/en/latest/editors/3dview/display/shading.html


Source for not sewing on Motzei Shabbos

Question: I know people that do not sew anything on Motzei Shabbos. What is the source for this Minhag?
Comment: Hi Earl. Did you try asking them? What did they say?
Comment: No. They would probably say that is what my mother did.
Answer: A source that I am aware of is the Mogen Avraham 299:15 who mentions in the name of the Avudraham that woman have a Minhag to refrain from doing work on Motzai Shabbos.
Comment: The Yerushalmi (Pesachim 4:1) says explicitly this is not a Minhag (as in, even though some people do it it doesn't have the status of Minhag).  נשיי דנהיגין דלא למיעבד עובדא באפוקי שובתא אינו מנהג.
Comment: @DoubleAA: Avudraham says Nahagu Hanashim
Comment: The Tur writes the samme loshon when talking about the bracha of שעשני כרצנו
Comment: I'm curious if there is any connection between this minhag (or whatever you wish to call it) and the act of the women sewing the curtains for the Mishkan. Offhand, I'm not sure what the connection might be, but, maybe there is something?
Answer: The minhag of refraining from  sewing  on motzei shabbas goes under the umbrella of women not doing melachos gedolos (defined by poskim). Rav Belsky in Shulchan HaLevi explains why sewing is singled out as the common custom.He explains that a woman knows how to sew in a proper (uman) fashion ,opposed to a man who sews like a hedyot (not an expert). Do they took on the custom to refrain of doing a maaseh uman,but only up until chatzos.
The Rivevos Ephraim 2:115:107 brings down many sources(Aruch Hashulchan says we go with the Yerushalmi which says its not a minhag,rather after havdalah melacha can be done) but ends off saying that sewing is the one melecha he knows ppl are machmir on as opposed to other meleachos.
Text of Shulchan HaLevi:

Text of Rivevos Ephraim:
Answer: I saw this in tamei haminhagim years ago. The reason given there is because that is the time that tachrichim were traditionally sewn.

Source for not sewing on Motzei Shabbos


What work is more, - 2J or - 5J?

Question: I was studying a concept different from newtonian mechanics, but there was a concept which confused me. if work done by constant frictional force is considered in an experiment there are two values of it, one is -2J and another is - 5J, which one will be more? I think following integer rules is not correct here as - sign just shows that force is not in direction of displacement.
Comment: Really confused by the downvotes here. I think it is valid to be confused by the use of a negative sign as an indication of "direction" rather than negative meaning "less" than positive
Answer: Negative work is just positive work with the energy repositories switched. "A does 5J on B", "B does -5J on A", and "5J of system energy was moved from A to B" are all the same statement.
Friction is a force by means of which energy is transferred from a system's kinetic energy (excluding thermal internal energy) to the system's total thermal internal energy. "Forces doing work" is misleading shorthand for one mathematical object that holds energy doing work on another mathematical object that holds energy by means of a force.
When your introductory text tells you that friction (with something attached to the ground or very massive) does -5 Joules work on Alice, you should mentally replace it with "5 Joules is transferred from the kinetic energy associated with Alice's movement to the system's total thermal internal energy by means of the force of friction."
Similarly for another common misleading phrasing: "the force of gravity does -5J work on Alice" should be "5 Joules is transferred from the kinetic energy associated with Alice's movement to the potential energy associated with the configuration of the system's masses (aka the gravitational field) by means of the force of gravity."
Comment: Thank you sir, I learnt many things new from your answer but I cannot understand which have done more work, one which caused 2J of energy to go into system's thermal energy or one that caused 10J of energy to go into system's thermal energy?
Comment: @rohan $-10 \lt -2$ no matter what you're counting, but the sign is a consequence of an arbitrary choice of direction and therefore so is the less-ness or more-ness. Just like "A does 5J on B" and "B does -5J on A" are the same statement, if $W_{AB_i}$ is an instance of work done by A on B and $W_{BA_i}$ is an instance of work done by B on A, $W_{AB_1} \lt W_{AB_2}$ and $W_{BA_1} \gt W_{BA_2}$ are the same statement. I much prefer to just state what actually happened than to worry about the words to use to describe an arbitrary choice of direction.
Answer: Negative work simply means the direction of the force on an object is away from the direction of the displacement of the object, i.e. the angle between the force and displacement vector is between 90 and 270 degrees. (In the case of negative work done by kinetic friction, it is 180 degrees.)
When a force does negative work on an object it takes energy away from the object. Kinetic friction is such a force. It takes kinetic energy from an object and dissipates it as heat at the sliding surfaces. The greater the negative friction work, the greater the energy taken from the object. Thus, -5J of kinetic friction work takes more kinetic energy away from an object than -2J of kinetic friction work.
Hope this helps.

What work is more, - 2J or - 5J?


Why run Visual Studio as "Run as Administrator"?

Question: What is the difference between using Visual Studio 2012 "Run as Administrator" mode and otherwise? Why do developers prefer using VS in administrator mode? What are the advantages/privileges that one gets?
I may be naive enough to ask this one but I am just curious. Thanks.
Comment: The only thing that I ever needed administrator privileges in VS for would be the Azure simulator, but [Stijn's answer](http://stackoverflow.com/a/20261828/73070) lists a lot more things. But few of these are typical, depending on what you do.
Answer: From MSDN: User Permissions and Visual Studio

You can do nearly everything in the Visual Studio IDE as a normal
  user, but, you need administrator permissions to complete the
  following tasks:

Installing Visual Studio.
Upgrading from a trial edition of Visual Studio.
Installing, updating, or removing local Help content.
Developing solutions for SharePoint 2010.
Acquiring a developer license for Windows Store.
Adding classic COM controls to the Toolbox.
Installing and using add-ins that were written by using classic COM in the IDE.
Using post-build events that register a component.
Including a registration step when you build C++ projects.
Debugging applications that run with elevated permissions.
Debugging applications that a run under a different user account, such as ASP.NET websites.
Debugging in Zone for XAML Browser Applications (XBAP).
Using the emulator to debug cloud service projects for Windows Azure.
Configuring a firewall for remote debugging.
Profiling an application.
Deploying a web application to Internet Information Services (IIS) on a local computer.
Changing how you participate in the Visual Studio Customer Experience Program.
Comment: I took the liberty of migrating the links too.
Comment: @aritra I wouldn't know, I have UAC disabled and don't need to do most of these tasks, but I assume the list is correct. If you find it isn't, please let us know :)
Comment: @Stijn Yes I am also not aware if all these tasks require VS to run on admin mode, its just that i was curious abt this one "Adding classic COM controls to the Toolbox."
Answer: Windows Vista introduced User Account Control which means that you are running all programs as a standard user even if you are an admin. There are certain things that you in VS that requires you to be running as an admin, not a standard user. For example running Windows Azure emulators, asp.net dev server, etc.
You can run VS as a standard user but sooner or later you will run into issues.


ConfigurationManager.AppSettings Performance Concerns

Question: I plan to be storing all my config settings in my application's app.config section (using the ConfigurationManager.AppSettings class). As the user changes settings using the app's UI (clicking checkboxes, choosing radio buttons, etc.), I plan to be writing those changes out to the AppSettings. At the same time, while the program is running I plan to be accessing the AppSettings constantly from a process that will be constantly processing data. Changes to settings via the UI need to affect the data processing in real-time, which is why the process will be accessing the AppSettings constantly.
Is this a good idea with regard to performance? Using AppSettings is supposed to be "the right way" to store and access configuration settings when writing .Net apps, but I worry that this method wasn't intended for a constant load (at least in terms of settings being constantly read).
If anyone has experience with this, I would greatly appreciate the input.
Update: I should probably clarify a few points.
This is not a web application, so connecting a database to the application might be overkill simply for storing configuration settings. This is a Windows Forms application.
According to the MSDN documention, the ConfigurationManager is for storing not just application level settings, but user settings as well. (Especially important if, for instance, the application is installed as a partial-trust application.)
Update 2: I accepted lomaxx's answer because Properties does indeed look like a good solution, without having to add any additional layers to my application (such as a database). When using Properties, it already does all the caching that others suggested. This means any changes and subsequent reads are all done in memory, making it extremely fast. Properties only writes the changes to disk when you explicitly tell it to. This means I can make changes to the config settings on-the-fly at run time and then only do a final save out to disk when the program exits.
Just to verify it would actually be able to handle the load I need, I did some testing on my laptop and was able to do 750,000 reads and 7,500 writes per second using Properties. That is so far above and beyond what my application will ever even come close to needing that I feel quite safe in using Properties without impacting performance.
Answer: since you're using a winforms app, if it's in .net 2.0 there's actually a user settings system (called Properties) that is designed for this purpose. This article on MSDN has a pretty good introduction into this
If you're still worried about performance then take a look at SQL Compact Edition which is similar to SQLite but is the Microsoft offering which I've found plays very nicely with winforms and there's even the ability to make it work with Linq
Answer: Check out SQLite, it seems like a good option for this particular scenario.
Answer: Dylan,
Don't use the application config file for this purpose, use a SQL DB (SQLite, MySQL, MSSQL, whatever) because you'll have to worry less about concurrency issues during reads and writes to the config file.
You'll also have better flexibility in the type of data you want to store. The appSettings section is just a key/value list which you may outgrow as time passes and as the app matures. You could use custom config sections but then you're into a new problem area when it comes to the design.
Answer: The appSettings isn't really meant for what you are trying to do.
When your .NET application starts, it reads in the app.config file, and caches its contents in memory. For that reason, after you write to the app.config file, you'll have to somehow force the runtime to re-parse the app.config file so it can cache the settings again. This is unnecessary
The best approach would be to use a database to store your configuration settings.
Barring the use of a database, you could easily setup an external XML configuration file. When your application starts, you could cache its contents in a NameValueCollection object or HashTable object. As you change/add settings, you would do it to that cached copy. When your application shuts down, or at an appropriate time interval, you can write the cache contents back out to file.
Answer: Someone correct me if I'm wrong, but I don't think that AppSettings is typically meant to be used for these type of configuration settings.  Normally you would only put in settings that remain fairly static (database connection strings, file paths, etc.).  If you want to store customizable user settings, it would be better to create a separate preferences file, or ideally store those settings in a database.
Answer: I would not use config files for storing user data. Use a db.
Answer: Could I ask why you're not saving the user's settings in a database?
Generally, I save application settings that are changed very infrequently in the appSettings section (the default email address error logs are sent to, the number of minutes after which you are automatically logged out, etc.) The scope of this really is at the application, not at the user, and is generally used for deployment settings.
Answer: one thing I would look at doing is caching the appsettings on a read, then flushing the settings from the cache on the write which should minimize the amount of actual load the server has to deal with for processing the appSettings.
Also, if possible, look at breaking the appSettings up into configSections so you can read write and cache related settings.
Having said all that, I would seriously consider looking at storing these values in a database as you seem to actually be storing user preferences, and not application settings.


Name of Jesus in the Quran

Question: I hear arguments from some christians that the name Esa is wrong as they say that Esa is from the word iesous and not yeshua, his Hebrew name. Is this a valid argument to challenge the reliability of the Qur'an that a wrong name is used, if that is the case? What do the scholars say about this?
Answer: Preliminary Remarks
Good question. There is a lot to be said on the subject. The debate about Isa and other various foreign (non-Arabic loanwords)  words goes back to the first centuries of Islam. The first thing to point out is that Iesous (Ἰησοῦς) is the Greek name of Jesus, as recorded in the Gospel (such as in Mark 1:9 here), which is from the Hebrew for Yeshua.
Lexical origin of Isa
Authur Jeffrey (1892-1959), who made substantial progress in the field of Qur'anic studies, published a landmark work in 1938 entitled The Foreign Vocabulary of the Qur'an that summarizes scholarship up to that point on "lexical borrowing" in the Qur'an citing many sources starting from early Muslim philologists and grammarians. Jeffrey's work presents 275 foreign words in the Qur'an (excluding proper nouns), "in which he compiled and presented all of his predecessor's studies," including the early Muslim philologists that recognized many words in the Qur'an as foreign, such as Isa.
According to Jeffrey, "the name [Isa] is still a puzzle to scholarship." Some have proposed that Isa is actually the name for Esau "and was learned by Muhammad from Jews who called Jesus so out of hatred" (this has been debated by Roediger, Landauer, Pautz, Derenbourg, and Rudolf). We don't have evidence that Jews called Jesus Esau, though. Another possibility is it being adapted from the Syriac word. Overall, however, the word "Isa" is not known anywhere prior to the Qur'an.
Jeffrey concludes that it is a consonontal permutation (variation) due to Muhammad that was perhaps influenced by Nestorian pronounciation (Nestorians were a large Christian group around Muhammad that would have primarily spoken Syriac, see Syriac Christianity).
Further Reading
I'm uncertain of what scholarship has progressed beyond this on the question. Here are some later developments on the subject that might help:

"Lexical Borrowings in the Qur'an" is an article that discusses Jeffrey's work and also mentions further developments that would be worth pursuing to answer this question!
The Syro-Aramaic Reading of the Koran by Christoph Luxenberg is another influential book (it also has been more criticized but still influential) that discusses more about words borrowed from Syriac that, he proposes, would change our understanding of many words in the Qur'an, such as changing "virgins"/chaste partners to "raisins." I'm uncertain if he discusses a Syriac origin of Isa.

Influential works that were already included or referenced in Jeffrey's work:

Judaism and Islam by Abraham Geiger (originally published in German in 1833 as What did Muhammad take from Judaism?) mentions 14 loanwords from Hebrew. Since Jeffrey referenced this work but not about Isa, it seems Geiger didn't make an argument for Isa being Hebrew in origin
Al Suyuti (1445-1505) published three relevant works, Risāla muhaḏḏab fī al-ᵓalfāẓ al-muˁarrab (literally "Pure Treatise on Arabized Words"), Al-Itqān fī ˁulūm al-qurᵓān [The Perfect Guide to the Sciences of the Qur'ān], and Al-Mutawakkilī include a total of 138 loanwords.

Conclusion
If Isa came from Iesous, since Iesous is correct, I don't see how this is a challenge to the reliability of the Qur'an. The only possible challenge to the Qur'an would be that Isa is perhaps (though many other words are certainly) of non-Arabic origin, which some may think contradicts the verses that say the Qur'an is revealed in (plain, pure, or clear) Arabic. See Qur'an 12:2, 16:103, 20:113, 39:28, 41:3, 42:7, 43:3, 46:12, 16:103.

Qur'an 16:103 "And We certainly know that they say, "It is only a human being who teaches the Prophet." The tongue of the one they refer to is foreign, and this Qur'an is a clear Arabic language."

However, many early Muslims freely noted the foreign origin of many words in the Qur'an. Al-Suyuti would say that although the words were borrowed from other languages, they were incorporated into the Arabic language so could still be called "Arabic." There were centuries of debate about this topic. Do with that what you will. So, here is the relevant data that I have, and you are welcome to explore more and come to a more firm conclusion.
Comment: I once watch this YouTube video that said eesa was the name of Jesus: https://www.youtube.com/watch?v=Y9_OYGaIwcQ
Comment: @AsanRamzan this really isn't much evidence, and is really only saying that the Aramaic name for Jesus sounds similar to Isa (which to me didn't sound like it at all). Some unanswered questions would be: How do you know the people are speaking Aramaic? How do you know they are speaking Jesus' name?
Comment: You can see the Aramaic form [here](https://en.m.wikipedia.org/wiki/Jesus_(name)#Etymology), and see the word as used in Ezra in Aramaic [here](https://biblehub.com/hebrew/3443.htm). So I think it is clear Isa is not from the Aramaic form of Jesus.
Comment: as to you first comment it is a well know fact that the predominate language at the time of Jesus was Aramaic. Since you do not know this I feel you either have not done your research or are not familiar with this feild. I have past in reseach, and generally we don't go to Wikipedia, it is bias especially considering the Christian majority.
Comment: @AsanRamzan. Yes Aramaic was the lingua franca of the day; that has nothing to do with my comment, which was about the people in the video. And yes, go to the sources linked in Wikipedia.

Name of Jesus in the Quran


Relay calls from one phone to another

Question: Does anyone know of an app (on iOS, Android or any platform) that will allow me to place one phone in a part of my house that has good phone signal, and have it relay all calls to another device using my home's WiFi?
Answer: Yes - handsfree bluetooth accessories will work to extend the range a good 25 or more feet in many cases. You could also rig a wire and have much, much longer extension, but I can't imagine wanting to be wired to the phone and using a handsfree in that manner.
There are many, many mobile base stations that work with all manner of cellular towers and technologies, so those would be my next choice if you can't get the phone close enough to reception for bluetooth to extend the range to your body.
Comment: It seems surprising that a solution that doesn't rely on additional hardware wouldn't already exist - I'd have thought that an app, installed on two phones, ought to be able to manage this. Even if only on jailbroken phones...
Comment: Seems like a big security risk to allow another device to tap into the calling data stream. At least people that are conscious of security can turn off bluetooth and/or not plug in a cord.

Relay calls from one phone to another


LinkedIn Api error

Question: I download the examble "linkedIntollkit"
I want to get my infor Account and friend list for my destop app.
this is the source.
 http://linkedintoolkit.codeplex.com/SourceControl/changeset/view/94877
I tried to run with their APi Key and secret ket (already in code) It run Ok. but when I changed them by mine. I can get

after I click "Allow access" I got error
"An eror occured(Access to connetion denied)"
this is my app confi

Please tell me what is wrong with my api.
Thank you.
Answer: Give a try to www.springframework.net/social-linkedin/
Comment: Thank you,bbaia. I tried "ConsoleQuickStart" project. I already got my Information. One more question, Do you know how to get friends'email from LinkedIn.

LinkedIn Api error


"register" keyword in C?

Question: What does the register keyword do in C language?  I have read that it is used for optimizing but is not clearly defined in any standard.  Is it still relevant and if so, when would you use it?
Comment: *What does the register keyword do in C?* gets ignored :)
Comment: @bestsss Not completely ignored. Try to get an address of `register` variable.
Comment: That code you're reading is *old* https://www.youtube.com/watch?v=ibF36Yyeehw#t=1827
Answer: It's a hint to the compiler that the variable will be heavily used and that you recommend it be kept in a processor register if possible.
Most modern compilers do that automatically, and are better at picking them than us humans.
Comment: A good reason _not_ to use 'register': you can't take the address of a variable declared 'register'
Comment: @Euro: You probably know this, but just to be explicit, the compiler is required to prevent the address of a `register` variable from being taken; this is the *only* mandatory effect of the `register` keyword.  Even this is sufficient to improve optimizations, because it becomes trivial to tell that the variable can only be modified within this function.
Comment: Note that some/many compilers will completely ignore the register keyword (which is perfectly legal).
Comment: Well, I experimented with register to get my ACM submissions tweaked, and sometimes it really helped. But you really have to be carful, because poor choices degrade performance.
Comment: ypnos: Actually the speed of a solution for ACM ICPC problems depends much more on the algorithm choice than on such micro-optimizations. The 5-second time limit is usually enough for a correct solution, especially when using C instead of Java.
Comment: It's still pretty useful in embedded. Decent compilers for embedded systems even allow you to set which variable goes into which register.
Comment: Modern compilers start by putting *all* scalar auto locals - in fact all distinct writes to such locals - plus basically all intermediate expressions - into separate 'virtual registers', and then set about working out how to map all those into actual registers and memory. So it's actually quite restrictive to tell the compiler to put a variable into a register. Some  variables may vanish completely (like the one used as the temp in a swap). I know this answer is 6 years old but it's more definitely true now, I'm pretty sure most modern compilers basically ignore 'register' for code generation.
Comment: @DaleHagglund (I know it's 4+ years later but) the flow analysis done by compilers includes detecting that situation regardless of the 'register' keyword, from the actual code. Also, if you *only* take the address of a variable in order to pass that address to an inline function, and that inline function only stores a value at that pointer, the compiler may be able to simplify that (given aliasing checks)  to a direct assignment to the variable. So, it could still be in a register, even with & applied to it. But this construct is prohibited with 'register' keyword.
Comment: @greggo: I understand that all modern compilers do the sort of analysis you describe, and that any scalar variable can end up in a register if it meets the right criteria. At least for me, the upshot of this is that I never use the register keyword anymore. It's a relic from the days when compilers weren't very good at intra-procedural dataflow analysis.
Comment: Also note that the effect of "register" (if the compiler chooses to respect it) will vary a lot between processor architectures and models. So even if "register" makes your program faster on your Pentium IV, it may make it slower on a Xeon, or an AMD processor, or a Sparc... . So it's really more like a last-ditch optimization.
Answer: I'm surprised that nobody mentioned that you cannot take an address of register variable, even if compiler decides to keep variable in memory rather than in register.
So using register you win nothing (anyway compiler will decide for itself where to put the variable) and lose the & operator - no reason to use it.
Comment: There is a reason actually. The mere fact that you cannot take a address of the variable yields some optimization opportunities: the compiler can prove that the variable will not be aliased.
Comment: By this logic `const` is also be useless since it wins you nothing, you only loose the ability to change a variable. `register` could be used to make sure nobody takes the address of a variable in the future without thinking. I have never had reason to use `register` though.
Comment: Compilers are notoriously terrible at proving that aliasing doesn't occur in nontrivial cases, so `register` is useful for this even if the compiler doesn't put it in a register.
Comment: @AlexandreC , Miles, compilers are perfectly OK at checking whether & is taken of a variable anywhere. So regardless of other difficulties about detecting aliasing, restating that buys you nothing.
When K+R first created C, it was indeed useful to know *in advance* that & would not be used, since that compiler actually made the register allocation decision on seeing  the declaration, before looking at the following code. That is why the prohibition is in place. The 'register' keyword is essentially obsolete now.
Comment: "There's no reason to use it" that's why they added it to the language.
Answer: It tells the compiler to try to use a CPU register, instead of RAM, to store the variable. Registers are in the CPU and much faster to access than RAM. But it's only a suggestion to the compiler, and it may not follow through.
Comment: Worth adding for people using C++, C++ lets you take the address of a register variable
Comment: @Will: ...but the compiler will likely end up ignoring the keyword as a result.  See my answer.
Comment: > "*without pass-by-reference you've seriously broken C++*"
I did no such thing. It was like this when I first saw it ;)
Comment: Yes, it seems that 'register' is a placebo in C++, it's just there to allow C code to be compiled as C++. And it wouldn't make much sense to prohibit &var while allowing passing it by reference, or const-reference, and without pass-by-reference you've seriously broken C++.
Answer: I know this question is about C, but the same question for C++ was closed as a exact duplicate of this question.  This answer therefore may not apply for C.

The latest draft of the C++11 standard, N3485, says this in 7.1.1/3:

A register specifier is a hint to the implementation that the variable so declared will be heavily used. [ note: The hint can be ignored and in most implementations it will be ignored if the address of the variable is taken. This use is deprecated ... —end note ]

In C++ (but not in C), the standard does not state that you can't take the address of a variable declared register; however, because a variable stored in a CPU register throughout its lifetime does not have a memory location associated with it, attempting to take its address would be invalid, and the compiler will ignore the register keyword to allow taking the address.
Answer:
I have read that it is used for optimizing but is not clearly defined in any standard.

In fact it is clearly defined by the C standard. Quoting the N1570 draft section 6.7.1 paragraph 6 (other versions have the same wording):

A declaration of an identifier for an object with storage-class
  specifier register suggests that access to the object be as fast
  as possible. The extent to which such suggestions are effective is
  implementation-defined.

The unary & operator may not be applied to an object defined with register, and register may not be used in an external declaration.
There are a few other (fairly obscure)  rules that are specific to register-qualified objects:

Defining an array object with register has undefined behavior.
Correction: It's legal to define an array object with register, but you can't do anything useful with such an object (indexing into an array requires taking the address of its initial element).
The _Alignas specifier (new in C11) may not be applied to such an object.
If the parameter name passed to the va_start macro is register-qualified, the behavior is undefined.

There may be a few others; download a draft of the standard and search for "register" if you're interested.
As the name implies, the original meaning of register was to require an object to be stored in a CPU register. But with improvements in optimizing compilers, this has become less useful. Modern versions of the C standard don't refer to CPU registers, because they no longer (need to) assume that there is such a thing (there are architectures that don't use registers). The common wisdom is that applying register to an object declaration is more likely to worsen the generated code, because it interferes with the compiler's own register allocation. There might still be a few cases where it's useful (say, if you really do know how often a variable will be accessed, and your knowledge is better than what a modern optimizing compiler can figure out).
The main tangible effect of register is that it prevents any attempt to take an object's address. This isn't particularly useful as an optimization hint, since it can be applied only to local variables, and an optimizing compiler can see for itself that such an object's address isn't taken.
Comment: so is behaviour of [this](http://ideone.com/QIatqM) program really undefined according to C standard ? Is it well defined in C++ ? I think it is well defined in C++.
Comment: @Destructor: Why would it be undefined? There's no `register`-qualified array object, if that's what you're thinking.
Comment: Oh sorry I forgot to write register keyword in array declaration in main(). Is it well defined in C++ ?
Comment: I was wrong about defining `register` array objects; see the updated first bullet point in my answer. It's legal to define such an object, but you can't do anything with it. If you add `register` to the definition of `s` in [your example](http://ideone.com/QIatqM), the program is illegal (a constraint violation) in C. C++ doesn't place the same restrictions on `register`, so the program would be valid C++ (but using `register` would be pointless).
Comment: @KeithThompson: The `register` keyword could serve a useful purpose if it were legal to take the address of such a variable but only in cases where semantics would be unaffected by copying the variable to a temporary when its address is taken, and reloading it from the temporary at the next sequence point.  That would allow compilers to assume that the variable may be safely kept in a register across all pointer accesses provided that it's flushed at any places its address is taken.
Answer: It hasn't been relevant for at least 15 years as optimizers make better decisions about this than you can.  Even when it was relevant, it made a lot more sense on a CPU architecture with a lot of registers, like SPARC or M68000 than it did on Intel with its paucity of registers, most of which are reserved by the compiler for its own purposes.
Comment: Compiler are and remain pathetic at being better than the developer in identifying absence of aliasing and hence practices that reduce repeated indirection (very costly) and help cache data locally are very much relevant.
Answer: Actually, register tells the compiler that the variable does not alias with
anything else in the program (not even char's).
That can be exploited by modern compilers in a variety of situations, and can help the compiler quite a bit in complex code - in simple code the compilers can figure this out on their own.
Otherwise, it serves no purpose and is not used for register allocation. It does not usually incur performance degradation to specify it, as long as your compiler is modern enough.
Comment: @greggo: Allowing a `register` qualification on global variables, whether or not the compiler allows the address to be taken, would allow some nice optimizations in cases where an inlined function that use a global variable is called repeatedly in a loop.  I can't think of any other way to let that variable be kept in a register between loop iterations--can you?
Comment: @greggo: Too bad `register` forbids taking the address at all, since otherwise it could be useful to let compilers know of cases where a compiler would be able to apply register optimizations *despite* a variable's address being passed to an external function (the variable would have to be flushed to memory *for that particular call*, but once the function returns, the compiler could again treat it as a variable whose address had never been taken).
Comment: @supercat I think would still be a very tricky conversation to have with the compiler. If that's what you want to tell the compiler, you can do it by copying the first variable to a second one which doesn't have '&' on it, and then never using the first one again.
Comment: @greggo: Saying that if `bar` is a `register` variable, a compiler *may at its leisure* replace `foo(&bar);` with `int temp=bar; foo(&temp); bar=temp;`, but taking the address of `bar` would be forbidden in most other contexts would not seem like an overly complicated rule.  If the variable could otherwise be kept in a register, the substitution would make code smaller.  If the variable would need to be kept in RAM anyway, the substitution would make code bigger.  Leaving the question of whether to make the substitution up to the compiler would lead to better code in both cases.
Comment: "tells the compiler.." no, it doesn't. All auto variables have that property, unless you take its address *and* use it in ways which exceed certain analyzable uses. So, the compiler knows this from the code, regardless of whether you use the register keyword. It so happens that the 'register' keyword makes it illegal to write such a construct, but if you don't use the keyword, and *dont* take the address in such a way, then the compiler still knows it's safe. Such information is crucial to optimization.
Answer: Storytime!
C, as a language, is an abstraction of a computer. It allows you to do things, in terms of what a computer does, that is manipulate memory, do math, print things, etc.
But C is only an abstraction. And ultimately, what it's abstracting from you is Assembly language. Assembly is the language that a CPU reads, and if you use it, you do things in terms of the CPU. What does a CPU do? Basically, it reads from memory, does math, and writes to memory. The CPU doesn't just do math on numbers in memory. First, you have to move a number from memory to memory inside the CPU called a register. Once you're done doing whatever you need to do to this number, you can move it back to normal system memory. Why use system memory at all? Registers are limited in number. You only get about a hundred bytes in modern processors, and older popular processors were even more fantastically limited (The 6502 had 3 8-bit registers for your free use). So, your average math operation looks like:
load first number from memory
load second number from memory
add the two
store answer into memory

A lot of that is... not math. Those load and store operations can take up to half your processing time. C, being an abstraction of computers, freed the programmer the worry of using and juggling registers, and since the number and type vary between computers, C places the responsibility of register allocation solely on the compiler. With one exception.
When you declare a variable register, you are telling the compiler "Yo, I intend for this variable to be used a lot and/or be short lived. If I were you, I'd try to keep it in a register." When the C standard says compilers don't have to actually do anything, that's because the C standard doesn't know what computer you're compiling for, and it might be like the 6502 above, where all 3 registers are needed just to operate, and there's no spare register to keep your number. However, when it says you can't take the address, that's because registers don't have addresses. They're the processor's hands. Since the compiler doesn't have to give you an address, and since it can't have an address at all ever, several optimizations are now open to the compiler. It could, say, keep the number in a register always. It doesn't have to worry about where it's stored in computer memory (beyond needing to get it back again). It could even pun it into another variable, give it to another processor, give it a changing location, etc.
tl;dr: Short-lived variables that do lots of math. Don't declare too many at once.
Answer: You are messing with the compiler's sophisticated graph-coloring algorithm. This is used for register allocation. Well, mostly. It acts as a hint to the compiler -- that's true. But not ignored in its entirety since you are not allowed to take the address of a register variable (remember the compiler, now on your mercy, will try to act differently). Which in a way is telling you not to use it.
The keyword was used long, long back. When there were only so few registers that could count them all using your index finger.
But, as I said, deprecated doesn't mean you cannot use it.
Comment: Some of the older hardware had more registers than the modern Intel machines.  Register counts have nothing to do with age and everything to do with CPU architecture.
Comment: @JUSTMYcorrectOPINION Indeed, X86 has basically six in all, leaving at most 1 or 2 for dedication to 'register'. In fact, since so much code has been written or ported to a register-poor machine, I suspect this contributed greatly to the 'register' keyword becoming a placebo - no point in hinting registers when there aren't any. Here we are 4+ years later and thankfully x86_64 has upped it to 14, and ARM is a big thing now too.
Answer: Just a little demo (without any real-world purpose) for comparison: when removing the register keywords before each variable, this piece of code takes 3.41 seconds on my i7 (GCC), with register the same code completes in 0.7 seconds.
#include <stdio.h>

int main(int argc, char** argv) {

     register int numIterations = 20000;

     register int i=0;
     unsigned long val=0;

    for (i; i<numIterations+1; i++)
    {
        register int j=0;
        for (j;j<i;j++)
        {
            val=j+i;
        }
    }
    printf("%d", val);
    return 0;
}

Comment: With gcc 4.8.4 and -O3, I get no difference. Without -O3 and 40000 iterations, I get *maybe* 50 ms less on a 1.5s total time, but I didn't run it enough times to know if that was even statistaclly significant.
Comment: There's no difference with CLANG 5.0, platform is AMD64. (I've checked the ASM output.)
Comment: Which GCC version and compiler flags are you using?
Answer: I have tested the register keyword under QNX 6.5.0 using the following code:
#include <stdlib.h>
#include <stdio.h>
#include <inttypes.h>
#include <sys/neutrino.h>
#include <sys/syspage.h>

int main(int argc, char *argv[]) {
    uint64_t cps, cycle1, cycle2, ncycles;
    double sec;
    register int a=0, b = 1, c = 3, i;

    cycle1 = ClockCycles();

    for(i = 0; i < 100000000; i++)
        a = ((a + b + c) * c) / 2;

    cycle2 = ClockCycles();
    ncycles = cycle2 - cycle1;
    printf("%lld cycles elapsed\n", ncycles);

    cps = SYSPAGE_ENTRY(qtime) -> cycles_per_sec;
    printf("This system has %lld cycles per second\n", cps);
    sec = (double)ncycles/cps;
    printf("The cycles in seconds is %f\n", sec);

    return EXIT_SUCCESS;
}

I got the following results:
-> 807679611 cycles elapsed
-> This system has 3300830000 cycles per second
-> The cycles in seconds is ~0.244600
And now without register int:
int a=0, b = 1, c = 3, i;

I got:
-> 1421694077 cycles elapsed
-> This system has 3300830000 cycles per second
-> The cycles in seconds is ~0.430700
Answer: During the seventies, at the very beginning of the C language, the register keyword has been introduced in order to allow the programmer to give hints to the compiler, telling it that the variable would be used very often, and that it should be wise to keep it's value in one of the processor's internal register.
Nowadays, optimizers are much more efficient than programmers to determine  variables  that are more likely to be kept into registers, and the optimizer does not always take the programmer's hint into account.
So many people wrongly recommend not to use the register keyword.
Let's see why!
The register keyword has an associated side effect: you can not reference (get the address of) a register type variable.
People advising others not to use registers takes wrongly this as an additional argument.
However, the simple fact of knowing that you can not take the address of a register variable, allows the compiler (and its optimizer) to know that the value of this variable can not be modified indirectly through a pointer.
When at a certain point of the instruction stream, a register variable has its value assigned in a processor's register, and the register has not been used since to get the value of another variable, the compiler knows that it does not need to re-load the value of the variable in that register.
 This allows to avoid expensive useless memory access.
Do your own tests and you will get significant performance improvements in your most inner loops.
c_register_side_effect_performance_boost
Answer: Register would notify the compiler that the coder believed this variable would be written/read enough to justify its storage in one of the few registers available for variable use.  Reading/writing from registers is usually faster and can require a smaller op-code set.
Nowadays, this isn't very useful, as most compilers' optimizers are better than you at determining whether a register should be used for that variable, and for how long.
Answer: gcc 9.3 asm output, without using optimisation flags (everything in this answer refers to standard compilation without optimisation flags):
#include <stdio.h>
int main(void) {
  int i = 3;
  i++;
  printf("%d", i);
  return 0;
}

.LC0:
        .string "%d"
main:
        push    rbp
        mov     rbp, rsp
        sub     rsp, 16
        mov     DWORD PTR [rbp-4], 3
        add     DWORD PTR [rbp-4], 1
        mov     eax, DWORD PTR [rbp-4]
        mov     esi, eax
        mov     edi, OFFSET FLAT:.LC0
        mov     eax, 0
        call    printf
        mov     eax, 0
        leave
        ret

#include <stdio.h>
int main(void) {
  register int i = 3;
  i++;
  printf("%d", i);
  return 0;
}

.LC0:
        .string "%d"
main:
        push    rbp
        mov     rbp, rsp
        push    rbx
        sub     rsp, 8
        mov     ebx, 3
        add     ebx, 1
        mov     esi, ebx
        mov     edi, OFFSET FLAT:.LC0
        mov     eax, 0
        call    printf
        add     rsp, 8
        pop     rbx
        pop     rbp
        ret

This forces ebx to be used for the calculation, meaning it needs to be pushed to the stack and restored at the end of the function because it is callee saved. register produces more lines of code and 1 memory write and 1 memory read (although realistically, this could have been optimised to 0 R/Ws if the calculation had been done in esi, which is what happens using C++'s const register). Not using register causes 2 writes and 1 read (although store to load forwarding will occur on the read). This is because the value has to be present and updated directly on the stack so the correct value can be read by address (pointer). register doesn't have this requirement and cannot be pointed to. const and register are basically the opposite of volatile and using volatile will override the const optimisations at file and block scope and the register optimisations at block-scope. const register and register will produce identical outputs because const does nothing on C at block-scope, so only the register optimisations apply.
On clang, register is ignored but const optimisations still occur.
Comment: In gcc, the `register` keyword can have a huge impact on the quality of code generated without optimization.  In some cases, using the `register` keyword may result in a compiler generating more efficient code at `-O0` than it can generate at higher optimization settings [e.g. at `-O0`, if a register-qualified object is loaded outside a loop, gcc will leave the load outside the loop, but at higher optimization settings it may replace the object with a constant that it ends up reloading within the loop].
Answer: On supported C compilers it tries to optimize the code so that variable's value is held in an actual processor register.
Answer: Microsoft's Visual C++ compiler ignores the register keyword when global register-allocation optimization (the /Oe compiler flag) is enabled.
See register Keyword on MSDN.
Answer: Register keyword tells compiler to store the particular variable in CPU registers so that it could be accessible fast. From a programmer's point of view register keyword is used for the variables which are heavily used in a program, so that compiler can speedup the code. Although it depends on the compiler whether to keep the variable in CPU registers or main memory.
Answer: Register indicates to compiler to optimize this code by storing that particular variable in registers then in memory. it is a request to compiler, compiler may or may not consider this request.
You can use this facility in case where some of your variable are being accessed very frequently.
For ex: A looping.
One more thing is that if you declare a variable as register then you can't get its address as it is not stored in memory. it gets its allocation in CPU register.
Answer: The register keyword is a request to the compiler that the specified variable is to be stored in a register of the processor instead of memory as a way to gain speed, mostly because it will be heavily used. The compiler may ignore the request.

"register" keyword in C?


How can you determine if a process is possible or impossible by using the 1st and the 2nd Laws of Thermodynamics?

Question: How can you determine if a process is possible or impossible by using the 1st and the 2nd Laws of Thermodynamics?
Answer: $\bf{Impossible}:$ A process is $impossible$ between two equilibrium states if at the beginning of the process the system and its surrounding has total $S_0$ entropy and at the end of the process the total entropy is $S_1$ $and$ $S_0 > S_1$.
 three comments:

between two equilibrium states: if you can define non-equilibrium
entropy then there are possible generalizations to include entropy
rates and non-equilibrium processes such that are centered around the idea that $internal$ entropy generation is always positive.

possible vs. impossible: One can reformulate the above negative statement of "impossibility"
to a positive one but not easily because, in general, not all
processes are possible just because the final entropy is larger than
the initial one. Ashes do not turn to gold just because the latter
might have higher entropy, there are also other conservation laws besides energy.

There are other that are sometimes more convenient formulations of the $impossibility$ statement. For example
<code> (a) the entropy of an *isolated* system cannot decrease, therefore in equilibrium  the entropy is maximum
 (b) the internal energy of a constant entropy system cannot increase and it is at a *minimum*
 (c) if a system can exchange heat only at a fixed given temperature than in
     equilibrium its free energy must be minimum.
</code>

There are many other similar variations but are all are essentially equivalent $impossibility$ statements.
Comment: Wow, thank you for this great answer. I am grateful. May I ask, if it's not too much trouble, what about if it's possible? I am assuming that knowing if it's impossible you can also know it's possible if the conditions are opposite, if I am not mistaken. I am trying to relearn thermodynamics, but I seem to have forgotten.
Comment: I am not sure how far one can go with what *is* possible. I said there are other conservation laws that a physical process must also observe, but I am fairly sure that if a process *is* possible than in a sufficiently small but finite neighborhood of *that* process other ones are also possible as long as the corresponding $S_0<S_1$


How to place components automatically according to a script in eagle cad?

Question: I am using eagle cad to design a clock with smd leds .There are 60 leds and i'll place those leds on a circle pattern which like an analog clock is there any way i can do this easily like a script or can i export components coordinates and angle data to a file then i can change them with a vim macro then import again ?
Answer: Yes, it is possible to place a bunch of parts in some regular pattern by using a script.  That is exactly how I do this sort of thing when it comes up.
Use whatever your favorite programming language is to write the script.  This should be little more than a bunch of MOVE commands that you execute in the board editor.
I use programs to write Eagle scripts enough that I have a library of routines that write out common elements of Eagle scripts and other related useful operations.  For example, I have routines that open a script file, write coordinates in Eagle format after a 2D transformation, various layered ways to adjust the 2D transform like rotation and scaling, writing characters, strings, floating point numbers, write MOVE commands, convert between coordinate systems, etc.
Don't think you'll only do this once, so take a few minutes up front to write the subroutines.   That will make this even easier the next time you need to automatically generate a Eagle script.


TTPhotoViewController Crash on iPad local images

Question: I'm going mad to try to figure out this problem and how to fix it. Basically I have an iPad app where I use sometime TTThumbsViewController and sometimes TTPhotoViewController, lunched by TTLauncherView. Everything works fine, I have to figure out some memory problem, but this is another story. The problem is when I use TTThumbsViewController everything works fine, when I use TTPhotoViewController on the simulator works great on the device crashes badly. If I use the code from the example TTCatalog, so images taken from internet it works fine, if they are local crashes. I see also a weird behavior the bottom navigation arrows work, but when I reach the beginning or the end I exptect one of them turn grey but they are still enable. I copy the exact file from the example TTCatalog but no lucky. Here the code:
import
<code> @interface PhotoBrowseViewController : TTPhotoViewController { NSMutableArray* data; NSArray    *parameter; }

@property (nonatomic, retain) NSArray parameter; @property (nonatomic, retain) NSMutableArray data;

@end;
import "PhotoBrowseViewController.h"
import "MockPhotoSource.h"
import "Utils.h"

@implementation PhotoBrowseViewController

@synthesize data,parameter;

(id)initWithData:(NSString*)level { if (self = [super init]) {
parameter = [level componentsSeparatedByString:@"-"];
data=[[NSMutableArray alloc] initWithArray:[Utils getPhotosBrowse:[[parameter objectAtIndex:0] integerValue]  andArray:nil]];

} return self; }

(void)viewDidLoad { self.photoSource = [[[MockPhotoSource alloc] initWithType:MockPhotoSourceNormal //initWithType:MockPhotoSourceDelayed // initWithType:MockPhotoSourceLoadError //initWithType:MockPhotoSourceDelayed|MockPhotoSourceLoadError title:@"test" photos:[Utils getTestPhotos]

photos2:nil ] autorelease];
</code>
}
<code>(void)viewWillAppear:(BOOL)animated { [super viewWillAppear:animated]; if(parameter!=nil ) [_scrollView setCenterPageIndex:[[parameter objectAtIndex:1] integerValue]];
</code>
}
<code>(void)updateChrome { self.navigationItem.rightBarButtonItem = nil; }

(void) dealloc { [super dealloc]; }

@end
</code>
And here the function:
<code>+(NSArray *)getTestPhotos {
return
[NSArray arrayWithObjects:
 [[[MockPhoto alloc]
   initWithURL:@"documents://f_0000000029.jpg"
   smallURL:@"documents://thumbs/f_0000000029.jpg"
   size:CGSizeMake(0, 0)] autorelease],

 [[[MockPhoto alloc]
  initWithURL:@"documents://f_2.jpg"
  smallURL:@"documents://thumbs/f_2.jpg"
  size:CGSizeMake(0, 0)] autorelease],

 [[[MockPhoto alloc]
  initWithURL:@"documents://f_0000000003.jpg"
 smallURL:@"documents://thumbs/f_0000000003.jpg"
 size:CGSizeMake(0, 0)] autorelease],

 [[[MockPhoto alloc]
  initWithURL:@"documents://f_0000000004.jpg"
  smallURL:@"documents://thumbs/f_0000000004.jpg"
  size:CGSizeMake(0, 0)] autorelease],

     nil];

}
</code>
I'm using iOS 5 and xcode 4.3. Three lib 1.0.11.
I notice that this happen only with jpg large like 2Mb. I'm still investigating, but it seems weird to me.
Can anyone help me? It will be much appreciated any good advices.
thank you a lot
Nibe
EDIT2:
I figure out the problem is not much about the dimension of the file but the resolution of the image, acutally they are something like 5616 × 3744, which is ridiculous high for my purpose.
I still have some crash in some big photos, any ideas how I can handle big pict?
thank you
Comment: what is the console output? which is the line where it crashes?
Answer: Read this
https://groups.google.com/forum/?fromgroups=#!topic/three20/AgD6iJmI-P0
Basically rule of thumb is use png format wherever possible.


Smoothing unregulated DC input voltage to a voltage regulator

Question: I am building a USB mobile charger powered by manually rotating a 12V DC motor shaft. This voltage goes as an input to a LM7805 voltage regulator and the output of the voltage regulator is used to power the mobile device.
When I measure the input voltage to the regulator, it varies from 7V to 11V. Since this is a high fluctuation of input to the voltage regulator, the mobile charger is rejecting the current.
However if I place a battery as an input to the 9V regulator, the mobile is getting charged with a current of 240mA.
I have tried placing capacitance of 4700μF at the input but to no avail.
I would like to know how could the input to the voltage regulator be smoothened so that the charger accepts the current.
Comment: The LM7805 is a very ancient device. You shouldn't use it here – it's very inefficient, and you'll not be able to use much of the power you generate by turning the shaft. What you want here is very clearly different; try adding more significant capacity to the motor output, and running a switch mode DC/DC converter from that. The definition of "significant" here depends on your turning and on the motor.
Comment: A very similar inquiry has been posted here https://electronics.stackexchange.com/questions/247322/voltage-regulator-minimum-input-voltage. The 7805 requires a minimum of voltage headroom between Vout and Vin. This is the so-called voltage drop. I believe this is 3 V for the 7805 implying at least 8 V applied to Vin to properly regulate a 5-V Vout. Look for 5-V low dropout regulators (LDO) which, for some of them, can operate down to a 300-mV dropout. However, a 1-V dropout in your case would seem to be good enough. The dropout depends on the delivered current.
Answer: Directly connecting a motor (acting as a generator) to an electronic circuit is going to cause problems. The most obvious one is commutation noise causing spikes that cyclically pulse the voltage to zero volts or even negative values. It won't be the same for every DC motor but you will get trouble from most.
The way around this is to half wave rectify the motor output and using a smoothing capacitor. You might also consider full wave rectifying the output so you can generate voltage when the motor turns in the opposite direction.
As Dmitry has said, a buck-boost converter is probably your best option because a 7805 will need typically 2 volts greater at the input to produce a stable 5 volts at the output. This means you need to guarantee 7 volts at the input (and after the diode(s)).
1st buck-booster from LT I looked at: -

You should also look at what TI can offer.
Answer: Try using a boost-buck converter instead of the linear regulator. These devices output a stable voltage whether the input voltage is higher or lower than the desired output, provided they manage to draw enough current. This will greatly increase the usable range of voltages from your generator: LM7805 will only provide 5V when it gets 6-12V from the generator, while a half-decent boost-buck converter would accept 3-12V. In the last case, a 4700μF cap should be able to provide enough smoothing.
Note that if your generator cannot output at least 240mA at 6V continuously, then all bets are off. You will need a more powerful one.
Also (unrelated to your question) if you see a schematic using 780X, 324 or 555 chips, try looking for alternatives, as there's a good chance that schematic was designed by dinosaurs.
Comment: Yes the 555 timer used as a basis for building a boosty /bucky regulator. Very Jurassic.
Comment: 555 converters appear frequently here.  Considering all the regulation problems and the huge integration available on the dedicated converter chips I can't understand why they're still used.
Comment: @PaulUszak I was referring to the timer / multivibrator chip. Is that what you had in mind?


Non-Archimedean non-standard models for R

Question: Let $\langle \mathbb{R}, 0, 1, +, \cdot, <\rangle$ be the standard model for $R$, and let $S$ be a countable model of $R$ (satisfying all true first-order statements in $R$). Is it true that the set $1,1+1,1+1+1,\ldots$ is bounded in $S$? My intuition says "no", but I am yet to find a counter example. I read something about rational functions, but I cannot verify it is, indeed, a non-standard model of R.
Comment: Why does a routine application of compactness not yield the model you want?
Comment: Dave, due to the high intersection of users between the MO and MSE communities it is considered impolite to post a question on both sites simultaneously. Please remember that for future reference. (Cross posted on math.SE http://math.stackexchange.com/q/133418/622)
Comment: @Juris Steprans: I'm sorry, I can't see what you're implying. Could you be more precise, please?
Answer: If $S$ is the set of real algebraic numbers then $1, 1+1, 1+1+1, \dots$ is unbounded in $S$. On the other hand, by compactness of first order logic (as Juris points out), there are models $S$ for which $1, 1+1, 1+1+1, \dots$ is bounded.
Comment: Yes, indeed. I think that a good solution for that would include adding another constant c to the language, then the theorems c>1, c>1+1 and so on, find a model and "forget" c (this is a model of the reduced language). Thanks!
Comment: Thanks for your answer. I'm afraid I don't understand how compactness comes in here. I'm guessing I should add the statements $\exists{x} x>1$, $\exists{x} x>1+1$ and so on to my set, and show that there are models that satisfy that set. But I think it only gives me that there are greater elements than any element of the type $1+1+\ldots+1$; I need one element that "covers them all".
Comment: No, that doesn´t work. You first need to add a constant to the language.
Answer: Take for $S$ the field $F(t)$ with $F$ being the algebraic closure of $\mathbb Q$ inside $\mathbb R$. Equip it with the unique ordering for which $t-x>0$ for every integer $x$, and take a maximal ordered algebraic extension of $F(t)$. The field $S$ that you get is real-closed, i.e., it has the same first-order theory as $\mathbb R$. It is countable, and has non-archimedean elements ($t$, for instance).
Comment: @GeraldEdgar While I agree with the general sentiment, the compactness theorem for countable theories does not need the axiom of choice.
Comment: Is it *so* different from the other answer? If you add a constant $t$ to the language with the axioms that it be greater than any integer $x$, then $t$ is transcendental and any model contains $F(t)$ — the simplifying point being that $F(t)$ is already real closed.
Comment: I think it is more satisfying to write down a concrete model like this.  Rather than depend on "compactness" which gives you a model out in "Axiom of Choice Land".
Comment: My construction is perhaps more explicit, and I can make it completely explicit (neither choice nor compactness involved): embed $F(t)$ into $F((s))$ with $s=1/t$ , and set $ K=\bigcup_n F((s^{1/n}))$. Equip $K$ with the ordering extending that of $F$ for which $s$ is positive and smaller than every positive rational number; this ordering extends that of $F(t)$, and makes $K$ a real closed field. Now you may take for $S$ the algebraic closure of $F(t)$ inside $K$.
Comment: And I disagree with ACL: $F(t)$ cannot be real closed. For instance, $t$ will never be a square in $F(t)$.


How many primary partitions can be created on a computer running Windows 8?

Question: I remember reading somewhere that as opposed to the former versions of Windows - more than 4 can be created, but I can't seem to find it on the web now. Is this true?
Answer: Strictly speaking, Windows only ever allows 4 primary partitions, because the phrase "primary partition" is only applicable to MBR partition tables and MBR partition tables only allow four primary partitions.
However, if you use a GPT partition table (available since Windows Server 2003 on 64-bit versions of Windows) you can have up to 128 partitions and do not need to distinguish between "primary" and "extended" partitions.
Depending on your computer model, you might not have the option of using a GPT partition table on your boot disk, because Windows only has native support for booting GPT disks via UEFI, not via BIOS.
What changed with Windows 8 is that computers sold with Windows 8 must (in order to be certified) support UEFI booting.  They must also ship configured to UEFI boot; as a consequence of this they must be shipped with GPT partition tables.
Comment: @Karan: Itanium is an entirely different kettle of fish, and my answer certainly wasn't intended to apply to it.  According to Wikipedia, Itanium uses EFI (the predecessor to UEFI) exclusively, i.e., there's simply no such thing as booting via BIOS on Itanium.
Comment: @RBT: it would probably be more sensible to mount any excess volumes onto directories rather than using device path syntax.  For example, `C:\Volumes\foo` or similar.  Although I'm not sure I can imagine a scenario in which it is sensible to have more than a dozen or so volumes in the first place!
Comment: "Windows only has native support for booting GPT disks via UEFI, not via BIOS" - This is only for consumer versions of Windows, right? Some server versions (for Itanium specifically) don't *seem* to have the UEFI requirement to boot from GPT disks as per [Wikipedia](http://en.wikipedia.org/wiki/GUID_Partition_Table#Windows:_32-bit_versions). Do you know if that's true and these versions can indeed boot from GPT disks without UEFI, just as Linux can?
Comment: I know your answer wasn't about Itanium; I just wanted some info on Windows support for GPT booting via BIOS. Seems you're right about the [Itanium using EFI](http://msdn.microsoft.com/en-us/library/ms952405.aspx), so thanks for clearing that up.
Comment: Though GPT partitioning scheme does allow 128 partitions but you can't assign drive letters to all of them once you have consumed 26 letters of English alphabet. So from 27th drive onward you have to follow volume ID scheme as described [here](http://superuser.com/questions/465730/access-to-a-disk-drive-using-volume-id-instead-of-a-drive-letter-in-windows) which will not be so easy to use for a normal user. In fact, since few drive letters are also consumed by your CD Drive, thumb drive or any network mounted drive so this limit can get exhausted bit earlier also.
Answer: The number of primary partitions isn't a limitation of the operating system, but of the partition table.

If you use an MS-DOS partition table, you can have up to four primary/extended partitions.
If you use a GUID partition table with default settings, you can have up to 128 primary partitions.

gptgen is able to convert an MS-DOS partition table into a GPT:

Gptgen is a tool to non-destructively convert hard disks partitioned in the common, "MSDOS-style" MBR scheme (including extended partitions) to use a GUID partition table (GPT).

I haven't tried the tool myself, but I found a few success stories on Google. Keep in mind that any modification of the partition table carries the risk of data loss.
Comment: Thanks. So can I change from one to another?
Comment: I've edited my answer.
Comment: It is my understanding that, at least for the disk containing the boot partition, you must use a MBR partition table if you are booting via BIOS and you must use a GPT partition table if you are booting via UEFI.  (At least, Windows setup enforces this requirement; there may be tricks you can use to bypass it.)
Comment: @HarryJohnston It seems that that was what I read. Thanks to your comment I searched and found that new computers that want to be Windows-8-certified (or something like that) must use UEFI. You can convert your comment into an answer. Thanks!
Answer:
You can have maximum of either 4 primary partitions or 3 primary partitions and one extended partition containing any number of logical partitions. If you don't have enough drive-letters to assign (A: B: C:...), you will have to mount the partitions as NTFS folders.
Windows creates a small system partition (a few hundred MB) for
recovery, boot and system data.
Answer: You could have more than 4 partitions far before Windows 8.
However, you can have up to 4 primary partitions or up to 3 primary partitions plus extended partition to hold logical drives (which are informally called "partitions" too). Those will work just as primary partitions in Windows.
Note that extended partition can't hold data itself, but logical drives do.
4 primary partitions is a limitation of MS-DOS partition table.
Answer: Once BIOS detects the bootable device then it executes the MBR (Master Boot Recorder).
MBR is 1st sector (512 Bytes) of the 1st bootable device. In 512 bytes, 3 parts are there :
i. 1st 446 bytes has primary boot loader information.
ii. Next 64 bytes for Partitions (16+16+16+16) for this reason only we are able to make 4 Primary Partitions.
iii. Next 2 bytes for validation check of MBR. (Magic Number)
Only one of the four partitions can be marked as active. Second boot loader is then loaded from 1st sector of this active partition which gives you an option to chose your OS to boot.
Answer: With the standard bios/MBR method you can have 4 Primary partitions, however this is not a good idea if you may want to add futher partitions later. Windows will automatically make the fourth partition an extended one, this ensures that you can add more partitions (space permitting) if required in the future, only one partition can be active and for DOS based systems (including W95/98) this must be the first partition.
Comment: As Windows 7/8 use a different method of booting it is possible to have 128 as mentioned previously.


How to change my Image DataImageUrlFormatString Value inside my GridView in Code?

Question: I have a gridview and the one coulmn is a image column.
How would i change the DataImageUrlFormatString value in my code behind?
i tried doing this but it does not work.......
((ImageField)(GridView2.Rows[0].Cells[0].FindControl("ID"))).DataImageUrlFormatString

 = "~/createthumb.ashx?gu=/pics/gmustang06_2.jpg";

Answer: Try this:
 ((System.Web.UI.WebControls.Image)(GridView2.Rows[0].Cells[0].Controls[0])).ImageUrl = "~/createthumb.ashx?gu=/pics/gmustang06_2.jpg";

EDIT:
You can set the URL of the path to an image that will be displayed in the image control with declarative syntax:
<asp:ImageField DataImageUrlField="id" DataImageUrlFormatString="img{0}.jpg"></asp:ImageField>

or in the Code Behind by handling the OnRowDataBound event of the GridView control:
protected void grd_RowDataBound(object sender, GridViewRowEventArgs e)
{
    if (e.Row.RowType == DataControlRowType.DataRow)
    {
        Image img = e.Row.Cells[0].Controls[0] as Image;
        img.ImageUrl = "img" + DataBinder.Eval(e.Row.DataItem, "id") + ".jpg";
    }
}

Comment: Thanks it does work, but what must i do and where if i want to change the Image field of each cell and not just on cell [0]. Like i have a Image field in my GridView and a ID field that i get from the DB. Do if the ID is 1 then i want to diplay Image1.jpg and if ID is 2 then i want to display Image2.jpg, and so on and so on. Will this have to be done in my RowDataBound event?


How to estimate displacement error using accelerometer

Question: I am using an MPU6050 and performing a double integration to obtain displacement, and this is to be placed in a vehicle that will be subject to about 2.5g. I cannot test it now, but how is it possible to estimate the error that the accelerometer will give me? Is it possible to use SIMULINK or MATLAB? If yes, could someone give me some pointers?
Answer: One way to test it would be to use a potentiometer that has a linear motion of knob. A hack for it could be to use a regular lab rheostat or for better accuracy, you may use a good damper position sensor if you can get one. You need to fix your MPU sensor on the knob (you may need to extend cables here) and also measure the displacement of the knob on potentiometer using ADC. Calibrate the ADC readings in your code using a ruler. Now you need to carefully move the knob, collect data from both ADC and MPU simultaneously and compare.
You need to be very careful about error induced in displacement measurement due to flaws of a setup like free play of knob, motion of sensor wrt knob, ADC calibration and quantization error etc. Try to minimize these. You may use MATLAB and SIMULINK to analyze the experimental data and may be to implement filters for your MPU but I don't think you can estimate the error on these tools without any physical experiment.


MVC is a kind of Design Pattern?

Question: While I was trying to concrete the concept of design pattern, I came up with a question: As I asked in the title, Is MVC(Model-View-Controller) architecture kind of Design Pattern?
Comment: Well according to tutorialspoint.com the answer is yes http://www.tutorialspoint.com/design_pattern/mvc_pattern.htm
Comment: Yet another MVC question. My advice is, don't ask about MVC theory here. The billions of different answers battling each other will only confuse you.
Comment: It's sometimes named `architectural pattern`, so a bit more high level than your common OOP design pattern since it works on the whole project structure and not only a single class (or small group of classes).
Answer: The Timeless Way of Building, which introduced the idea of Patterns was written in 1979, and it took another decade until programmers started to take Christopher Alexander's ideas and apply it to software (Design Patterns: Elements of Reusable Object-Oriented Software was released in 1994).
The original MVC paper(s) were written starting in 1978, before the introduction of the concept of Patterns and ~15 years before this concept reached the programming world. So, Trygve Reenskaug certainly did not think about it as a Pattern.
However, in modern terms, I would characterize it mainly as a User Interaction Design Pattern, which also influences Software Architecture and Software Design, so it also has some traits of a Software Architecture Pattern and a Software Design Pattern. But the main focus of MVC is User Empowerment and the Direct Manipulation Metaphor, both of which have nothing to do with Architecture or Design, they are all about User Interaction.
Answer: Yes and no and it depends. MVC is one of the terms which once had a very specific meaning, but then have grown in use to become a much broader and less specific term.
The original use of MVC was specifically as a oo design pattern used when coding desktop GUIs in Smalltalk. The pattern was specifically concerned about separating the data displayed in a form from the UI controls used to display the data, and the input gestures (mouse clicks etc.) used by the user. This was an early attempt to structure GUI code, and many more refined GUI patterns have developed since (patterns like Model-View-Presenter, Model-View-Viewmodel and so on). Martin Fowler have written a nice overview of the history of the MVC pattern as used in GUIs.
Later someone decided to reuse the term MVC for structuring web applications a certain way. It is not really the same pattern, but you can say that web MVC was inspired by the separation of concerns in the original MVC. It is more of an architecture than a classic pattern though. You will get really confused if you try to apply your understanding of the original MVC pattern to how the terms are used in MCV web apps - for example what is called the view in web-MVC corresponds more or less to the model in classic MVC.
Now MVC is often used to describe a whole web application framework, like in Microsofts Asp.net MVC framework.
Even then, some old timers continue to use the term MVC for a specific patten used when developing desktop GUI code. So in short, MVC can mean very different things depending on who you ask.

MVC is a kind of Design Pattern?


How can I prevent WiFi router owner from seeing what websites I visit?

Question: Like when using public wifi, what can I install/use on both my Android phone and Windows laptop to make it impossible (or very difficult for someone who is not an expert) from seeing what websites i visit?
Answer: You can route your connection through a VPN.  This will encrypt the connection from your device to the VPN provider, therefore making it impossible for the wifi router owner to scan your traffic.  See Understanding VPNs : How VPNs can be used for anonymization? for more info.
Answer: I would recommend using a VPN (Virtual Private Network), and of course, it should be switched on immediately after connecting to the WiFi access point. A VPN would encrypt your network connection, so that even a skilled network admin would find it nearly impossible to see your traffic.
Comment: Unfortunately, after technical corrections, this now looks exactly like the other answer.


What is the difference between single and double quoted strings?

Question: What is the difference between single and double quoted strings?
Is there a way to get a variable expanded inside a string, or do they always need to be joined like: 'Hello, ' . s:name . '!'
Answer: The only difference between single and double quoted string is related to backslash. To display special characters like newline, bells, tabs, etc, you need to use double-quotes -> "\n".
Within a single-quoted string, '\' is itself => '\n' is a two-characters string (a backslash + n). Within double quotes, you have to double it -> "\\", which makes them un-practical to define regexes.
Regarding string expansion, you have a few choices:

'Hello, ' . s:name . '!'
join(['Hello, ', s:name, '!'], '') -- which we never use
printf('Hello %s!', s:name)
lh#fmt#printf('Hello %1!', s:name) -- from lh-vim-lib, when we don't want to know about types, and when we don't need to format fields, but when we want to use formats like: 'Hello %1. How are you doing %1 this %2'.
Comment: @TomHale. Yes it is. Double it. -> `'foo''bar'`, or use both kind of quotes: `'foo'."'".'bar'`
Comment: Is it possible to include `'` inside a single-quoted string?
Answer: In the Vim documentation a double quoted string and a single quoted string are both referred to as a string constant.

double-quoted :help expr-string
single-quoted :help literal-string

The help lists the difference for single quotes as:

This string is taken as it is.  No backslashes are removed or have a special
meaning.  The only exception is that two quotes stand for one quote.

Because I'm a Javascript developer I see quite a lot of similarity with the single and double quoted strings there - but obviously string contactenation is done with . in Vimscript.
Further information from Learn Vimscript the Hard Way - Strings that has the default kind of string is a double quoted strings with a special section for Literal Strings

Vim also lets you use "literal strings" to avoid excessive use of escape sequences.
...
We'll revisit literal strings when they become most useful, later in the book (when we dive into regular expressions).


How to make an inclined plane in ODE?

Question: I am wondering how to make an inclined plane using ODE that a block will slide down. I don't want the plane to be infinite; ideally I want objects to fall off the edge of it so I probably actually need a large flat box. I know how to make basic objects like boxes, spheres, cylinders but am not sure how I can lock a box in place in mid-air? Or is it best to use a large triangular prism type shape which sits on the ground? I am using the ODE implementation built in to Panda3D game engine.
Answer: Please consult the ode documentation:
http://opende.sourceforge.net/wiki/index.php/Manual_(Collision_Detection)#Plane_Class
A plane can only be 'static' in ode so you don't need to lock it. The vector that you specify with the (a,b,c) parameters correspond to the normal of the plane. This would allow you to specify the orientation. For example (sqrt(2)/2,sqrt(2)/2,0) would be plane with a 45 degrees orientation in respect to having a Y up. The last param 'd' specifies the offset of the plane.
As for Panda3D, there is a wrapper for the plane class creation:
http://www.panda3d.org/manual/index.php/Collision_Detection_with_ODE
The Vec4 param should correspond directly to the (a,b,c,d) parameter used by the ODE lower level.
I hope this helps.
Comment: I think my question was badly worded and I have changed it. I don't want an infinite plane, I actually want a finite plane, so that for instance an object could fall off the side. Probably what I need is just a large flat block, but I don't know how to lock this in place in the air so that it doesn't just fall down to the ground.
Comment: I haven't tried it myself on Panda3d, but I would think that the wrapper uses the same approach that ODE does. You can create a geometry, in your case probably an OdeBoxGeom object, and not attach it to a body. Have you tried that? In ODE, geometries without a body are static.

How to make an inclined plane in ODE?


Moving /var/mail to different partition, drive or pc

Question: My managed server (Ubuntu 16.04, Postfix, Dovecot) had random accedent and in the end mail server was not working. Postfix had random randomness and it couldnt access mysql and Im using virtual users whit postfix and dovecot. Reapplying permission to db user it was quite working, mail was incoming but users cannot login. I fixed that by changing passwords, disabling appguard and maybe something else, I was in panic. Now it works, I hope so still and question is I have an idea to move /var/mail to different partition, drive or pc, create full os partition volume image backup and in case like this just use yesterdays backup image and mail server should from place where it stopped working. Is it possible or is a good idea is first place?
Answer: Your question is very hard to read. If you're interested in backing up your mail and configuration, you can simply copy the contents of the configurations from /etc. If you want to backup the mail-store, you can copy /var/mail. You can copy these anywhere you want.
For simplicity, I would suggest creating a tar bundle with a command such as the following:
tar czf /path/to/safe/backup/location/<backup-name>.tgz /etc /var/mail
This will create a compressed tar file which contains all of the configurations in /etc (including Postfix and Dovecot) and also all of the email from /var/mail