2011-12-31

The Paper Crane and the public static int main(string[] args)

"all languages suck"
-- some one

Why We Still use C: a case for Vala

So I have been lookingn at the Vala pagraming lanuage, and I must say I am inpressed... But why does it compile C code? Why does it not just compile straight to machine code?

The awnser is simple:

If it were to compile to machine code it would be hard, if not impossible, to reuse the librarys you make in Vala in other programs. This is the same problem that we have with CXX, CXX code is, virtualy, only reusable in CXX. While C code can, and is exposed to, vitualy, all other lanuages (Exept mabye Assembler and LISP).

An other poblem with CXX is the there is no single "true" STL, the standard does not explisetly define the functions, only interfaces, expected behaviour and expected output. Not the functions themselfs. This makes code/library reuse ard if not imposible.

In C there is one set of base librarys, only one, they have the some behaviour as all the rest of the implimentations of them. Take look at rand() function for example, is is well defined it K&R. and it looks, vitrualy, the same in all implimentations of the C Standard Library(ies).

But the again, C standard library on Windows has itoa() which is not (atleast i can not make it work) in GCC / the GNU implimentation.

This is why, when you make a library think about portability, reuse and other lanuages then your favorit. Use C (or Vala) for the love you have for your hacker brothers, sisters and undifined.

Here is a good video on C, Vala, Python and GObjects that sums up why we still use C:


Oh and BTW: I am going to write a game in Vala, and maby create a library for colliton detection for SDL_Rects.....

EDIT

ehm.. peopel, if anyone has would like to have Mono runtime/jit bindings in Vala, and would like to mentor me in the magic of .vapi files and the Mono class structure, I could do some work on that...

2011-11-21

The paper crane and the void.

"I feel so dumb" -- you.

Tell we what to write about



So I have not posted here in a while, well I have University to attend and such, so I do not get so much free time/spare biological prepossessing power to think about random shit I find.


So I give you a challenge:
Tell me what to write about.

If that does not work then here is today topic:

The fall of youtube

You see that quote at the top?

Well that is how I feel when I now go to youtube, there is no longer any debates or flame wars on youtube, this is like what I thought youtube was never going to be, large corporate channels and dumb entertainment.

I mean, I basicly now only go to youtube to watch the yogscast play MineCraft. Where are all the heroes of old? Where is edible napalm and the gang now? where is the debate? Has the trolls in us gone to sleep? Tell me.

I loved the old youtube, without all the crap, now the top and featured videos are not by Edward Current or CapnOAwesome (We miss you Kevin <3, and the world needs you).. no now music videos are at the top.

This is saddening to me, it was like when I thought that the Tribes Universe was dead, But now I see hope in Tribes: Ascend and Tribes Universe, but there is no Linux Client as it seems now. (back on track!).

I think that the debate started to die when CapnOAwesome left[1]. The steam went out of the balloon so to say. When two peopel on the same side start to fight, it became uncomfortable.

Then youtube made a redesign, making small channels hard to see, and that is concreted though newer versions of youtube.

So for the love of all that is good, Google fix youtube, have a now system where small channels get pushed to the top in a "new channel" section or have a "Debated videos" section.

Just sayin.

And to round of this post, here is ThunderF00ts take on this:



[1] I reject you reality and substitute my own.

2011-08-21

We dont need you

"Science is the shit" -- someone.

On Science


I was watching a rerun (I think) about Science Journalism, and one of the people speaking (a reporter from The Guardian) talked about the necessity of science and and why we need to make it interesting to people in the larger world, and tell them "You can not live without science!". He also talked about the partnership between them and Ten Alps on a project called Newton.tv (but that is another story).

Back to topic!

I have heard people say shit like: "Why should we spend this huge about of money on Science when there are people starving?" My answer is rely not that politicly correct: "you look to short sighted on the problem, we need science to solve the problems at hand, we need to educate people in what is wrong with the way they do things and to give them the mental tools to make there own future and to help the spices as a howl to evolve" (not maybe this well formulated or this long, but the gizt of it).

And I sometimes chock myself with thoughts like: "Why should we help them? They are enpoveraged and can not see the things they do wrong, why give live to 10 kids when you can barley feed yourself?"

But then I remind myself that theese are humans too... They are just less educated and are religious, which makes them more vulnerable to irrational beliefs which leads to lower education.... and so the wheel of enpoveragment spins.

No the only whay to "save the world" is to (let me borrow a quote from the Qatar fond (I think)) "Help people help them self" using science as the path we all must walk, even if we trample on some tows on the way.


Love Gego XAREN

2011-07-28

Re:Self

I think I should clarify what I saied in the last blag post...

Re:Days




>"I do not consider my self a racist" -- me

This is true

>*Tow days after the event in Norway*

>I was listening to what the panel on TV (Watching NRK via SVT) had to say after the event in Norway yesterday, and I was chocked at what they had to say about the assailant. He seemed to have had some of the same thoughts as I had once and that made me think.

>Could That guy, the assailant, have been me? someone who is outspoken against terror and Islam (not Muslims in general)?

I am also against Christianity, Judaism, Hinduism, Buddhism etc etc.
This is due to what I think of religion. Religion is a way of controlling people, but have we not advanced from the savage ways of religion?

>It could have... but I am against needless killings, so no.

>I do not think that there is anything wrong with the basic idea of multiculturalism, but I am against the phear that people have of offending others, that is what I am against.

Nothing to add here.

>I mean I love my dömer kebab with chips, and I think that some of the Middle Eastern, Asian, or African girls can be quite cute.

mmmmmm kebab... And females of the species Homo Sapient are good too.

>What I am against is what I have always been against: fear of offending, fear of telling people how things are and how stupid they are for believing the shit they do.

I wish that I was brave eghnuff.... sigh why con you not spell enough as it sounds?

>And I am against indoctrination, this is the worst of em all, kids are led to believe that there is a cosmic dictatorship that will punish them if they disobey, it is terrorism of children, and I call it child abuse, I even want to put it at level with sexual abuse of someone in a position of dependence.

>And btw, the assailant was Christian, I am not.

Atheist... if you do not get the gist of what I am tellin ya.



Side note


I relay need an apartment in and/or around Skövde...

2011-07-24

Days

"I do not consider my self a racist" -- me

Tow days after the event in Norway


I was listening to what the panel on TV (Watching NRK via SVT) had to say after the event in Norway yesterday, and I was chocked at what they had to say about the assailant. He seemed to have had some of the same thoughts as I had once and that made me think.

Could That guy, the assailant, have been me? some one who is outspoken against terror and Islam (not Muslims in general)?

It could have... but I am against needless killings, so no.

I do not think that there is anything wrong with the basic idea of multiculturalism, but I am against the phear that people have of offending others, that is what I am against.

I mean I love my dömer kebab with chips, and I think that some of the Middle Eastern, Asian, or African girls can be quite cute.

What I am against is what I have always been against: fear of offending, fear of telling people how things are and how stupid they are for believing the shit they do.

And I am against indoctrination, this is the worst of em all, kids are led to believe that there is a cosmic dictatorship that will punish them if they disobey, it is terrorism of children, and I call it child abuse, I even want to put it at level with sexual abuse of someone in a position of dependence.

And btw, the assailant was Christian, I am not.

2011-07-14

Anti-Shit hits the Shit.

“Life is the shit that happens while you're waiting for moments that never come.”
~ Lester Freamon on Life

I got accepted to Högskolan I Skövde, computer science.....


so to celebrate I decided to make a blag pasta.

and insert a youtube video of cats.



But the sad thing is.... I nood now to get an apartment in schoewdeh... ehm.. skövde, but I am an thet too.

soo wish me luck then..


I think I should stop posting random semi cat related videos on my blog... so I will... This was a one off.

2011-06-29

I have now translated my CV to English...

see post post posted 2099-01-01 13:37...

2011-06-18

This is the last time i will see your face..

"It is over, man is over!"

Why religions has to die, and what it will do to us as a species


I hate dislike religion as many of you already know. And I want it to disappear, become a footnote in an obscure past, not something we have to contend with now in this time and age, the age of reason. That is why I will first give religion merit for what it has done to us as a species.

The good


Stability in early homo sapient society, with out the stabilising force of religion I think that it would have been feasible to have created the society that we see to day. With out this stability we would not have seen think like the Grate Pyramids of Giza, the Sistine Chapel, or the Pyramids of the Aztec and Inca.

No I can only give credit to religions to make people do this.

Science would not have come in to being without the stability that was offered by religion, just think of who made the early scientific discoveries, they were of high statue even before there discoveries (or least of higher class then the mob) , this due to the eco-socio stability that religion gave. (I am talking about the 14-18-hundreds here, I know that there were even earlier discoveries then that, but those have been past to obscurity, only to be rediscovered)

The bad


I talked about eco-socio stability before, now think of who had to pay for this, was it the church? the priests? the upper class?

No, it was the lower class that has been pushed into there boots and the ground from religious bigots and religion.

Well the problem still is here, look out of the window and you will see people who are oppressed by there religion, be it women in burkas or hidjabs, or the cut Jewish boy, or the catholic girl who has been told that she is going to hell, or is possessed by the devil.

To tell there children what is right and wrong is good, but when you start mixing in religion you are just a fakking child molester, a torturer, you fakking swine!

Religion - Treat it like it's your genitalia. Don't show it off in public and don't shove it down your children's throats.

The Ugly


So what will come after region? Will it be more peaceful?

I do not know what will come after religion, I highly doubt that religion will ever be nullified, I see it only as a goal to reach for, to lessens its influence over people.

Wars will still happen, it it unavoidable that it will, be it over the slavery of sentient robots (ref: Alistair Reynolds - Revelation Space series - Conjurers) or "my mum told me you were a ugly swine", it will happen.

Will war be more frequent?
hell no! There will be no religious zealots in office that think that they have a direct phone line to (the) god(s).

So what will replace religion?
I suspect that there will be a now rise of ideology as religions diminish.

will there be less idiots?
ehh.... you are reading my blog, I think you know the answer to that one.

hay mr talaban turn over bin ladi... oh wait...

"I do not see my self as a racist, but some times you just have to look at statistics"

Islamic cultural terrorism


2011-06-07

living in tho matrix

"‪Has anyone really been far even as decided to use even go want to do look more like?

The Typematix 2030.

So As some of you may know I suing a Typematrix keyboard (since December 2010 CE) and is is the bomb I tell you.
the enter in the middle and the non-staggered keys... and the...

But relay, what do I think about it? Was it worth the hefty amour of money? and has my tying improved?

I like it, I like it a lot, I never though that I would like a non-mechanical keyboard, but I do. I like this one. it is quiet and it has a good key size, not to big not to small.

I thought that the absent of a num-pad would suck, but it rely is no use for it when you have the keys on top.

has my typing improved over my old G15? I like to think so, but I still have not gotten up to speed with touch typing. I truly suck at it. and that was true on the G15 too.

Am I more accurate with the Typematrix 2030?
No. I still have a hard time remembering where the keys are. this is even more true on a standard OWERTY keyboard.

Worth it? perhaps, I can now type without hand strains, but I still have an old OWERTY habit: pressing space with my index finger. But to be serius: no I do not think it was worth the money, I could have gotten a Happy Hacker Keyboard, But they do not have the svorak layout on the keys. So I will stick with this one till it dies on me.

One other thing I like is the Silicone Skin, makes cleaning a lot easier.

Over all:
Worth it: 6-7/10
Quality: 9/10

//AOEUIDHTNS

2011-05-09

And so shit hit the fan!

This post will be in swedish.

Tävling blir jobb?


Jag går Grafisk Kommunikation på Grebberstads Folkhögskola och så hade vi en gästlärare so gav oss i uppdrag att göra en design till en tävling... jag tänkte "oh yeah! man kan vinna 10 papp!"

I dag när jag skulle lägga upp mitt förslag så läste jag reglerna... det var det jävligaste jag har sett:

* Formgivaren bakom vinnande mönster får en
 vinstsumma på 10.000 kr. 2:a och 3:dje
 pristagarna får 5.000 respektive 3.000 kr.
 Vinstbeloppen betalas ut som lön och utbetalas
 efter avdrag för preliminärskatt, alternativt
 betalas ut mot faktura till företag med
 F-skattsedel. Eventuell vinstkatt betalas av
 vinnaren. Vinstsumman till förstapristagaren är
 slutlig ersättning för mönstret.

* DesignTorget äger rätten till det vinnande
 mönstret och har rätten att använda detta mönster
 på valfria produkter.

* DesignTorgets rättighet till det vinnande
 mönstret gäller under obegränsad tid.

* Formgivaren bakom vinnande mönster får inte
 sälja det vinnande mönstret vidare till någon
 annan eller själv producera produkter med mönstret.

låt oss repetera:
[..] Vinstbeloppen betalas ut som lön [..]

Japp de kallar tävlingen för ett jobb... hur fan kan man motivera något sådant? Antingen är det ett jobb ELLER en tävling, Det är inte tillåtet att marknadsföra ett jobb som en tävling. punkt-fakking-slut!

Är de så insnöade i sina gammelmedia rollen att de inte kan ge ge konstnärer rätt till sin egen konst? Nej fy på er NöjesGuiden och DesignTorget. Ni bör skämmas! Att göra falsk marknadsföring och sedan ta ifrån konstnären sin rätt. Fy på er!

/me spottar NöjesGuiden och DesignTorget i andsiktet.

2011-04-27

I hate base 10

"Money is only worth anything if you believe it is worth anything"

Bitcoin

I recently discovered this "new" thing called BitCoins. it is a virtual currency that is based on p2p networking and cryptography trickery.

The idea behind Bit coin is that there is a finite number of coins that can ever exist, this is hard coded in to the system. the second is that new money is made by solving complicated sah256 cryptography calculations: you will receive 50 BTC (Bitcoins) if some conditions are met.

are they worth any thing?

why yes as of this moment the current trading rate for BTC is 0.8 EUR/BTC or 1.5 USD/BTC



The good


P2P.

It is anonymous.

It solves some Cryptography calculations.

There is no central "bank" to speak of.

You can use it to day.

The bad


There is no central bank.... bubbles can burst an no one can stop it. Eco crime will become impossible to track.

Deflation problem. Due to the fact that there only ever can be a finite number of coins the "Deflation Spiral Effect" can start to make the markets unstable and collapse. (That is why on one use gold-, silver-, or copper standard any more.)

The not so good and not so bad


The rate of the coins exchange is a market, you can sell and by it like if it was stock, and play the market. This makes it a good currency, but it also creates a uncertainty among the dealers.

Send me your coins!

Send em here:
1GV2yimh5NGkG5SXvMuTLQ8Dbdg8oiKok

rurrent rates and xechanges

https://www.aurumxchange.com/
https://btcex.com/
http://coincard.ndrix.com/
Full list:
https://en.bitcoin.it/wiki/Category:Exchanges
exchange rate:
http://bitcoinwatch.com/
get 0.05 BTC:
http://freebitcoins.appspot.com/

2011-04-26

Finding the hidden

"if it is not on google it does not exist"
-- Some marketing guy at a company in Sweden who got booted from google.

A proposal for the W3C


I have been looking at different search engines and found that the king of kings is still Google, but there is a problem with Google: no one knows how it works, and they have a total control over the web, b/c "if you can not be found on google you are dead".

This seems OK for most of us, but some see it a big problem. So do I.

The proposal


I propose that the W3C put together a working group for "the federated search engine".

why you ask?

b/c it is more ethical to have a distributed web then a static one, the web we have is so static that it hurts to think about it.

There are already many meta search engines and open p2p engines. but they falter in that they are a) using the same old engines that are the "kings" of the web or b) they are unmoderated, and prone to manipulation.

What I propose is something radically different: a federated search engine, consisting of web crawler nodes that run on the engines, then the nodes can subscribe to other engines to got updates or query them for answers.

The thing with this is that you could use simple, already in use tech to do this. and the engines can blacklist and white list results according to patterns or methods.

each engine could have different methods of doing there crawl and prioritising of results. and different nodes can do different things, some only index universities an other only forums and so on.

and if a site wants to be indexed they can send an API request to the nodes to show that they exist. and if nodes decide that the request is spam or malice they can get blacklisted, but only on that node.

Full node search


Now then, how do we do queries without causing mayhem on the web? awnser: Full node search.

the full node search will query all the (known) nodes for an update, then do a regex of the data, and build a response to the query.

the full node search can (if wanted) send queries to the different nodes for them to pull the latest priorety list, count, black/white list, and meta data from the the node that requested the full node search update.

the white listing and black listing of sites can be done by the users, flagging and proboting.

the Process of flagging should be simple and not to complicated: just hit [flag] button by the link and you get asked "why?" and there is a drop down list of answers ("offensive" should never be on such lists), then you will be asked for your e-mail (this should not be mandatory) then the flag request is of.
to prevent the flagging from being exploited the node should track the flaggings and if there is a spike of flaggings of one site bar flagging of the site and SysOps are noted to look into the matter.

the same goes for whitlisting, or promoting, but here you have to log in, with OpenID or simmilar to shaw that you are a real porson, then you will be asked for your e-mail and then an e-mail is sent to confirm the request.
Same spike logic applies here as in the oxamplo of flagging.

I LOVE GOOGLE!

just saying.

they promote FLOSS and have a big role in the fight against OOXML in the ISO. even if it phaild it was a good effort that we all are grateful for.

The SOC projects are a grate initiative, and relay pushes FLOSS to become more friendly with to the devs.

Thank you Goggle.

2011-04-25

nathing now.

"And that is why we do not let him out, Jim"
Sam Harris Puts It Straight

Since I have troubled coming up with any real content I will just post this video here....



The full speech: http://2tu.us/3b4e

2011-04-16

I can not eat that! it is Pi(e)



I am Just leaving thin here.

Original Video:
http://www.youtube.com/watch?v=jG7vhMMXagQ

TinyOgg video: http://tinyogg.com/watch/9SFvY/

The tau manifesto: http://tauday.com/

2011-03-27

the cutter cutting the cutter

"hello forum" -- RWJ
UN -- The end of it self.
A few days ago (11 03 24) at school there was a lecturer holding lecture about the UN and the work it does, the current Arabian revolution, and how "we" can help by not helping.

This lecturer has been an UN-soldier, Worked for the Swedish Military and mush more - he, Per Erik Korsström, Told it straight and with resolve. He "put the cards on the table" as we say in Sweden about the Arabian revolution, how the US helps suppress the people around the world, and why no one is helping in Sudan, Darfur and other places.

The betray of the west.
Was something he spent a long time talking about. It was interesting to hear how the west has betrayed the Arabic world, First after the First World War, Then the creation of the state of Israel, Third the First Gulf War - Not taking out Saddam Hussain when they were so close to Baghdad. The last betray was actually a orderd by Other Arabian states, the general in charge of the first Gulf war was not even American, He was Saudi (or something - I do not quite remember what Korsström said).

The blue berets -- blue helmets -- UN-soldiers.
One interesting thing that he brought up was that the UN-Soldiers are soon gone, there are very few countries that actually send soldiers to do UN-service, Sweden -- My home land -- has no UN-soldiers at all, this is a huge difference between the old war Sweden did things and the new, before we sent of the most soldiers to do UN-service of any country, now non. We have soldiers in other countries, yes, but they are not funder UN flag, but NATO flag. This despite we being officially "alliance free".

End of conscription in Sweden -- a betray against the world.
Korsström argued that the end of conscriptation in Sweden made for more aggressive soldiers, this due to that when they do military service it is not there profession rather a service to the country, or the UN, they do it to help, and so on.
He told us about his experience of Bosnia and how the Swedish peace keepers were kind and respectful to the locals, but the Americans and the British were hostile to everybody. he argued that this was due to that for the Brits and the Americans it was there profession, while the Swedes did this a a service.


The most dangerous leader in the world.
Is, according to Korsström, is Netanyahu (president of Israel). This due to his and the Israeli militarise utter disrespect for UN treaties and there utter disrespect for civilian life.
There are war treaties that that that a military action only has to be as grate as is required, and should be in proportion.
This is something that something that is not the case when it comes to the Israeli militarise raid against Lebanon last year (?) when 5 Israeli soldiers were kidnapped.... the outcome was that 500 Lebanese civilians died, this is not in proportion, and is a war crime.
why has not any Israeli leaders been taken before the court in Haag? simple: the veto of the USA (period).


The USA is not the only one who does not want interference in different conflicts around the world, China and Russia are vetoing against many interventions around the world.
 
End notes

Here is two interviews with him ( in Swedish) and to give you a better wive of who he is.




2011-03-19

The paper crane and the world wide sea

"I am worried" -- me
On copyright again.

As the few readers of this Blag may know, I wrote about the book "free culture" a wire back.
I have just listened to
Glyn Moodys (@glynmoody@identi.ca) key note at FSCONS it relay fits in to the last "article" i wrote on the subject of copy right.

here is the video:

Glyn Moody - Keynote: Ethics of Intellectual Monopolies from FSCONS on Vimeo



Curriculum Vitae
BTW.
I have made a CV so yee guys can get a better view of who I am...
It is is Swedish so do not expect to be able to read it.
   bzr branch lp:~gustav-hartvigsson/+junk/CV
or here

2011-02-19

The moon has fallen

Hi there this is just a random blag post.
A Report, And Some Code
I did a project at school (it is some random filler coarse) and I wanted to show you what I have done.

first of: The project is in Swedish, so do not expect te be able to read it, but the change log is in English.

I Used BZR and launchpad to do the work and keeping track of the changes, so you can grab the code here:

https://code.launchpad.net/~gustav-hartvigsson/+junk/Dataanalys

or via bzr:

bzr branch lp:~gustav-hartvigsson/+junk/Dataanalys

For the PDF click here.

2011-01-13

Heritage

A huge part of our heritage is turning to dust as we speak, this due to the the extension on Copyright terms. this dust is made of the once grate films of the past, made on nitrous-base. just turning to dust.

edit at the end.....

Copyright: the double edged sword.
I am listening to "Free Culture" a book by Lawrence Lessig and I get infuriated with how the media companies and the MPAA could not support the "The Eldred Act" but instead demand that it would hurt copyright holders.
there argument went something like this: "We con not let other peoples movies get in to the public domain, cus we will not have control over the public domain. It is better that the cultural heritage in these moveis turn to dust!" -- Jack Valenti of the MPAA
This is not relay what he said, but it was the essence of it.

Well I relay hove nothing to say about this, I encourage you to read the book, available here and here( Audio Book) and here.

So
the double edged sword:
I am a copy right holder, when I make a note to my dad, that is copyrighted, when I write here, it is copyrighted, it is my work, I own it. But, is it rely necessary that you are not allowed to reprint this, in any way shape or form until 50 years after my death?
No, it is not.
If I were to make a book ( whish I hope that I will one day do) I will put on the first page: "In event of my death this work will become Public Domain" and/or "This work will become public domain after 25 years of its initial publication.
Why?
Cus, all the revenue that I will probably make will be a) during my life time b) with in 25 years of its first print.
How do I know this?
Easy: I have books in my shelf that is no longer in print, and I have no Idea how to contact the copyright holder if I wanted to make an digital version of it and make public so that this grate works would "stay alive" so to say. I have to wait till the copyright owner dies, then wait 50 years more.
He would not make a dime of its digital copy, granted, but he does not make a dime of it now. So I think that something like a shorter copyright term (say 25 years) would be ideal, and then have the right to extend it for a fee of something like 1€ to extend it an other 25 years and then again, but no more then 75 years.


But then we have software. I wonder what the FSF and the GNU project has to say about this? I mean is the project as a howl one work, or is every file its own work? if you do the sums you will soon see that it all adds up if you were to extend the licence term of some of the projects, so they do not pass in to the public domain. And if the were to become public domain the GPL would be nullified on old revisions. this making them fair game for leeches.

You can see where I am going with this.

When I write or draw stuff that I put up on the net, I always put it under CC-BY-SA (not including this blog ATM), this due to I want my work to not become orphaned in case of my death, but put in it archives, and be part of a time line of human history, my "thoughts echo on in future minds" so to say.

I relay thought that I had something to say here, but my knowledge in the subject is limited, so I will end this post here.


Edit:
Found this on the intratubez: http://www.youtube.com/watch?v=FhTUzNKpfio it is a video by from TEDxNYED with Lawrence Lessig.
Even though I hate Conservatives and Libertarians, he makes a good point.
(I am the lefty lefty, free market loving, free culture promoting guy)...

2011-01-05

The code

"I am mad!" -- someone

EDIT: Some one does not know what the One True Brace Style is... Let me help you google it.


My problems with the coding standard that are in use today.
I have so many problems with the coding standard for c-like languages in most project: first of the idea that starting brackets should be on a new like, this makes the code IMHO look like fuck:


class foo()
{
x=2+3;
print(x);

}


Am I the only one that sees the problem with this? The fukking bracket is not on the same line as the class! it is an eye sole!

The brackets on a new like makes the code look messy, and hard to read. It looks like a coding error to me.

this is the way it is suppose to be done:

class foo(){

x = 2 + 3;
print(x);

}

it is no longer an eye sore.

So how did the coding standard that is in use today come to be so popular?
The KnR style was invented by Kernighan and Ritchie's book The C Programming Language* and I can draw the conclusion that this book was read by many future programmers, and then these programmers started projects, and wrote books about programming which then inspired others.... A downward spiral of programming style.
And this downward spiral was accelerated by the the coding standard enforced by GNU** that encapsulated lodes of project that are a part used in our day to day lives.

I am a promoter of the One True Brace Style*** or its derivitive that is intended at making the more reader friendly. Even the Whitesmiths Style**** is better then the KnR Style, even though the end brace is at the wrong level.

help out and stop this downward spiral in to coding hell and convert your code from KnR to 1TBS or one of its derivative.

On White Spaces VS Tabs:
I do not give a fukk, I like tabs, but white spaces can be better if you are doing code with many indentation levels. b/c as you know a line of code has to be less then the 80 characters/columns ( this is just a standardised convention for interoperability and niceness of code)***** and with a tab taking up eight characters we have a when you hit the tenth level in your code.
And btw, gedit converts my tabs to what I want if I want.

* http://en.wikipedia.org/wiki/Indent_style#K.26R_style
** http://www.gnu.org/prep/standards/standards.txt
***http://en.wikipedia.org/wiki/Indent_style#Variant:_1TBS
**** http://en.wikipedia.org/wiki/Indent_style#Whitesmiths_style
***** I have lines that are longer then 80 chars, but I try to minimise it as much as possible.

2011-01-02

Physics and Life

"Build a man a fire and he will be warm for a day, Teach a man how to make fire and he will be warm the rest of his life" -- someone

Education phails - Why do I need to know physics?
I have been looking in to higher education and find it has relay high requirements for prior education: I need no have done the A and B* coarse in Physics to be able to attend the courses I have been looking at (Programming and Computer Science -shy). Here is the problem: I do not have Physics B .... I have to go and "read up" those courses, But I do not want to do it over the intrawebs (done that, I phaild miserably) , or with a bunch of High School Students who are running around...

Why do I even need to know Physics to write code and thesis? It does not make any sense. I think that I would fit in to the "IT"-crowd at UNI quite well and be a "good" student. I already know some basic Python, C, PHP, (Java) and such. I see no reason why I need to know Physics when I am working on a computer science thesis or collaborating with my mates on a project.

Time to restructure the system!
I am a advocate of the "system of basic knowledge before entering a program"-procedure, but sometimes that hurts the system.
As an institution, the unis have to keep up a standard, but that standard is set by the students previous education, not the students real Knowledge. I can get "competence" in a subject by doing courses and doing good in class and on the tests, but that is not a test of real knowledge only temporary or surface learning, not real learning. An admission test would be a better test, a test that you had a week to do a test that consists of a number of points like: write a program to do X, what were your sources for this? Do a collaborative project with a/two test mate(s), How did you collaborate? what were the problems you encounter? write an essay on any subject you like. etcetera etcetera.

Or have a system where you can submit a personal paper, some code you have been working on, some of your prior essays and a letter of approval from some one. and that would weigh as much as any degree or mark. (provided you have a basic minimum degree).

What are your thoughts on this?

* http://translate.google.se/translate?js=n&prev=_t&hl=sv&ie=UTF-8&layout=2&eotf=1&sl=sv&tl=en&u=http%3A%2F%2Fsv.wikipedia.org%2Fwiki%2FFysik_B