BBC Micro Bot - <AUTHOR> http://www.8bitkick.cc/bbc-micro-bot.html <comment><USER3> There is a really good online emulator as well.

[https://bbc.godbolt.org/](https://bbc.godbolt.org/)

I had one of these when I was young and it pretty sport on with how I remember it.

<comment><USER4> Interesting - this comment was marked as 'dead' until I upvoted it - some sort of over-zealous spam filter misinterpreting "bbc"?

I was a Spectrum guy myself, but I did write my first C program on an Acorn Workstation clone.

<comment><USER5> An "Acorn Workstation clone"? That sounds interesting.

Do you mean one of their Unix workstations (basically an ARM based Archimedes running a clone of Unix) or a third party clone of some other Acorn kit?

Using either would be unusual and interesting to hear more about. Thanks.

<comment><USER4> One of these: [http://www.computinghistory.org.uk/det/33101/Acorn- Cambridge...](http://www.computinghistory.org.uk/det/33101/Acorn-Cambridge- Workstation/) with a TI 32016 processor & using a BBC Micro for UI - <USER2> that my housemate Colin thought it was a bit expensive, so reverse engineered the board, redesigned it to be a little smaller (this was in the mid-80s & chip specs were changing rapidly), wire-wrapped a prototype for testing, then etched five proper PCBs, of which only a couple were populated.

<comment><USER6> An article about that board in some computer magazine of the time (probably PC World) was the first time I had heard of Unix and C - I was amazed at the same of C code they gave - no line numbers!

Edit: This was probably 1983 when I was 17 and my programming experience was based on Apple II and Sinclair machines.

<comment><USER4> Rather than Unix, our Workstation ran Panos, the only operating system that I know of named after a Greek restaurant.

<comment><USER6> I never got nearer than a magazine review to one of those beasties so I am probably getting the OS part wrong - but I do vividly remember wondering what #include did.... :-)

<comment><USER5> [https://en.wikipedia.org/wiki/Panos_%28operating_system%29](https://en.wikipedia.org/wiki/Panos_%28operating_system%29)

<comment><USER4> And this is the (now defunct) Panos restaurant, on Hills Road:

[https://i2-prod.cambridge- news.co.uk/incoming/article1345494...](https://i2-prod.cambridge- news.co.uk/incoming/article13454940.ece/ALTERNATES/s1227b/Panos- restaurant.jpg)

</comment></comment></comment></comment></comment></comment></comment></comment></comment><comment><USER7> Very cool. For bonus points, try to escape from the emulator!

</comment><comment><USER8> Wonder what would happen if one were to tweet it a fork bomb. I'd hope they have a mitigation for that.

<comment><USER9> I don't think it's possible to fork a process? At any rate the example code is basically an infinite loop... So I think you get to do pretty much whatever for you 50 seconds of runtime..

<comment><USER10> Yup, that machine had literally no notion of a process. You could say it was strictly single-process: whatever is in memory is what gets run...a fork bomb would require breaking out of the VM.

</comment></comment></comment><comment><USER11> had a bit too much fun with this the last few days, but had an idea and trying to get it into a tweet (without minifying) was fun - wanted more of a typing effect but lack of way to delay/wait/slow BBC BASIC flow or get timing right with GIF maker (should've read doc note! it generates the gif after 18 seconds and then for only 2 seconds long). Still very neat, takes me back to my <ahem> youth.

</comment><comment><USER12> BASICTwitter

</comment><comment><USER13> Example code on the website:

      10 MODE 2
      20 COLOUR RND(7)
      30 PRINT "HELLO WORLD"
      40 GOTO 20

Happy to see "colour" spelled the English way. :-)

<comment><USER14> You should have use "spelt" then :-)

<comment><USER15> "Spelled" is more common now even in British English. E.g. compare a Google search of 'site:bbc.co.uk "spelt"' with 'site:bbc.co.uk "spelled"'. Most recent usage of "spelt" is referring to the grain, or a direct quote of somebody who prefers the old-fashioned spelling.

<comment><USER4> Dr. Johnson gives both spellings in his Dictionary, along with relevant quotes from Milton and Dryden, which are all spelled "spelled" or "spell'd".</comment></comment></comment></comment>


SkipTheDishes denies wrongdoing as more billing fraud cases come forward - <AUTHOR> https://globalnews.ca/news/6079509/skipthedishes-denies-wrongdoing-as-more-billing-fraud-cases-come-forward/ <comment><AUTHOR> I have had few situation wherein the order placed was never delivered after 90 minutes and then they go on to cancel the order because they were unable to find delivery drivers. I go and pick up the order and then have to bicker on their chat support to return the delivery fee at least. Talking to a few restaurant owners gave me the impression this happens way more than usual.

</comment><comment><USER2> Could not the customers credit card information be stolen from the internet/sketchy store/night out and then be used by the hacker to order food? Hard to say who is at blame here.

</comment><comment><USER3> Last month I was looking at the skipthedishes iOS reviews and they were flooded with these accusations. I've used the service for a few years without issue but some people have had bad luck</comment>


What You See Is Not What You Get: Weird Behaviors in S3 Bucket Policies - <AUTHOR> https://github.com/elfakyn/knowledge/blob/master/src/cloud/aws/services/s3_bucket_policy_weird_behaviors.md <comment><AUTHOR> I wrote this up since, over the past year, I've encountered more and more weird behavior with s3 bucket policies.

I haven't seen all of this behavior documented in a single place, so here it is.

Some of it has security implications (such as being able to brute force usernames) that is worth knowing about.

A TL;DR of the security stuff:

* Brute-forcing valid principal names is possible, since you can't create a bucket policy with an invalid principal.

* User compromise will break cross-account access, since if AWS becomes aware of a compromise, they will want you to delete the user and recreate it.

* Explicit denies will stop working if the principal is deleted and recreated, since they operate internally on the Principal ID and not the ARN

* Canonical IDs offer no extra security compared to account ARNs, since it's trivial to convert them back and get an account number.</comment>


The Crisis of Democracy [pdf] - <AUTHOR> http://www.trilateral.org/download/doc/crisis_of_democracy.pdf <comment><AUTHOR> The setting is 1975, but the ideas are familiar:

"There has been a substantial relative decline in American military and economic power, and a major absolute decline in American willingness to assume the burdens of leadership. And most recently, the temporary slowdown in economic growth has threatened the expectations created by previous growth, while still leaving existent the "postbourgeois" values which it engendered among the youth and intellectuals."

"The system becomes one of anomic democracy, in which democratic politics becomes more an arena for the assertion of conflicting interests than a process for the building of common purposes."

I've just skimmed it so far, and found distasteful their general theme that the "crisis" is that there was too much of it, and the kids would not "Respect Mah Authoritah". However, they did include a dissent, which also brings up many themes that are still timely in 2020:

Appendix I.B "Excerpts of remarks by Ralf Dahrendorf on the governability study"

"Is growth presumably growth of a gross national product? Is this the only kind of expansion of human life chances which we can think of in free societies?"

</comment><comment><USER2> This seems to be a thoughtfully critical take on it:

... This general "crisis of democracy," the commission held, resulted from the efforts of previously marginalized sectors of the population to organize and press their demands, thereby creating an overload that prevents the democratic process from functioning properly. In earlier times, "Truman had been able to govern the country with the cooperation of a relatively small number of Wall Street lawyers and bankers," so the American rapporteur, Samuel Huntington of Harvard University, reflected. In that period there was no crisis of democracy, but in the 1960s, the crisis developed and reached serious proportions. The study therefore urged more "moderation in democracy" to mitigate the excess of democracy and overcome the crisis. ...

The Trilateral Commission study reflects the perceptions and values of liberal elites from the United States, Europe, and Japan, including the leading figures of the Carter administration. On the right, the perception is that democracy is threatened by the organizing efforts of those called the "special interests," a concept of contemporary political rhetoric that refers to workers, farmers, women, youth, the elderly, the handicapped, ethnic minorities, and so on-in short, the general population. In the U.S. presidential campaigns of the 1980s, the Democrats were accused of being the instrument of these special interests and thus undermining "the national interest," tacitly assumed to be represented by the one sector notably omitted from the list of special interests: corporations, financial institutions, and other business elites.

[http://www.thirdworldtraveler.com/Chomsky/Necessary_Illusion...](http://www.thirdworldtraveler.com/Chomsky/Necessary_Illusions.html)</comment>


Abolish Performance Reviews - <AUTHOR> https://medium.com/@haacked/abolish-performance-reviews-1af610b0d23f <comment><USER2> Complaining about performance reviews seems similar to complaining about the tech interview process: there's general consensus it's bad and has many shortcomings, yet companies keep doing it and few feasible alternatives are put on the table.

Also, I don't see much of a difference between "classic" performance reviews and the "360-degree reviews" that the article mentions, other than the latter having better branding.</comment>


Show HN: SenderPays - Pay the Recipient and Get Noticed - works over email - <AUTHOR> http://senderpays.co

<comment><USER2> This has been a great idea for almost two decades now. It's just waiting for brilliant execution. Is this the one? Maybe.

I hope it takes off, it would solve a lot of problems with email.

Advice, you guys should try to sign up some celebrities so people can get started right away. For example, I'd like to try it but I don't have the email address of anyone I might want to email.

<comment><AUTHOR> Yes, it's a very old idea and recently Esther Dyson has been championing it though my eagerness to see it through was when I couldn't email a doctor that was treating me since she wouldn't give out her email address because she knew better but heck I would have paid the same price as for a face-to-face consultation to to reach her by email!

I think anyone who'd want a response from just about anyone could make use of this just like I would have to contact my doctor (provided she'd given her email address) and the same applies to journalists, consultants and even the author of your favourite cook book, anyone you'd want advice from :)

Just released SenderPays for Custom Domains which allows anyone to set it up on their account - for instance email rehanw at yahoo dot com to get an idea.

Thanks for the feedback!

<comment><USER2> It still seems like the main problem to contacting someone famous/important is the the sender doesn't know their email address.

I'd say if you could have a list on the front page of some examples of people you can email (who have signed up) it would go a long way.

Maybe even try to recruit some minor internet celebrities?

<comment><AUTHOR> That's the problem, because anyone can contact you the most sensible thing is not to display your email address but with a system like this or something similar that could change for the better because usually when you email someone you want something, and in most cases your willing to compensate that person for their time.

Take for instance a finance blogger, you could possibly send an email but then most people are already doing that so currently you don't stand out but if you think that person's time is worth $50 you could pay that person an incentive with the hope of getting a reply, no reply then you get a full refund.

Currently email and the internet in general don't place a value on people's time, but that's changing because Google can't provide the answers to all our questions - sometimes the experts opinion is what's required and it's time their compensated, it's only fair.

</comment></comment></comment></comment><comment><USER3> If the goal is anti-spam, BTC is the ideal currency (e.g. "I only accept emails that come with at least 0.0001 BTC."). Paying for a response, though, seems easily gamed.

<comment><AUTHOR> Spam has been fixed for the most part, this has to do with actually getting a response for your message, especially when contacting a person who gets a lot of email. Paying an incentive to the recipient puts a value on their time, just like you would when paying for a doctor or a lawyer offline, you're paying for their advice otherwise why else would you be trying to contact them.</comment></comment>


Announcing Flutter beta 1: Build beautiful native apps - <AUTHOR> https://developers.googleblog.com/2018/02/announcing-flutter-beta-1.html <comment><USER4> The responses to this article are pretty discouraging to be honest. Cross platform mobile development is a pain in the ass. React Native is a step in the right direction but, as anyone that has actually used it knows, it still has some very rough edges.

Here's a completely new platform with a forward thinking, reactive UI model and fast but flexible language that offers a much less painful environment for us to live in day to day and all people can do is crap on it because it isn't JavaScript and they have to learn a new, very slightly unfamiliar language.

You can learn a lot about why programming is such a shit show by reading the comments on this one.

<comment><USER5> I can't speak for everyone, but my problem with flutter isn't the framework - it's the language. Or, more accurately, the fact that it's _not_ a JVM-based language.

When Android came out, it was able to piggyback on millions of existing Java packages (such as Apache commons). When Kotlin came out, it was able to piggyback on millions of existing Java packages _and_ Android packages (and even better, existing Java code can seamlessly forward work with Kotlin).

Now, Google is using its muscle to drag everyone to its language which has pretty much no existing adoption.

Oh. And many remember Dart being optional-typed (like Typescript).

<comment><USER6> Well Flutter does provide for a way to call into existing native code so I think that mitigates the code-reuse concern. The other thing to consider is that this advantage of code reuse was never realized to iOS. Writing apps for iOS & Android always meant having a C/C++ core with platform-specific shims; J2Objc more recently let you write it in Java but again that just lets you write the core in Java with 2 platform-specific independent frontend implementations. A lot of developers just wound up writing the app twice & shifting as much logic server-side as possible (which hurts battery too). This is the first time you can write the app once & run on both iOS & Android. AFAIK Dart is also only a requirement for the front-end. You are still free to use whatever language you want for your business logic. I'm not 100% clear yet on how good the bridging story is but I suspect it's not bad.

<comment><USER7> You could also use a C++ core with Qt/QML to target not only iOS and Android but also Windows, macOS and Linux, all from the same codebase.

<comment><USER8> Wow, let me stick the hot pokers in my eyes first! Qt/QML in a mobile app is something only a masochist could love.

<comment><USER7> It depends if you're trying to make your UI consistent with other apps on the platform, or consistent across platforms.

</comment></comment></comment></comment></comment></comment><comment><USER9> I recently rewrote a small app in flutter that was originally react native. Initially I was sceptical, mainly about learning dart. But it wasn't hard to pick up.

I found the development experience much smoother than react native, things just worked, whereas in react native there were many many small bugs and issues with the many packages required.

Flutter IDE support is good with the intellij plugin [1]. Performance, I didn't do any benchmarks, but a simple list with thousands of items feels much smoother on flutter than react native. There are packages for redux as well in flutter, so state management is taken care of [2]. The only downside I experienced with flutter is that Json handling is clumsy, apparently because flutter doesn't support reflection, which would be necessary to have comfortable Json-decoding like with Javas gson or go's json package [3].

Another thing to consider is that react native will render on one thread, and handle the application logic on another thread, but that means the application logic is still restricted to a single javascript thread, which can lead to bottlenecks eventually. From what I understand (haven't tested), dart can work multithreaded, having an advantages there.

End of the day, I would chose flutter over react native. Mainly because of Javascript and all the pain that comes with it.

[1] [https://plugins.jetbrains.com/plugin/9212-flutter](https://plugins.jetbrains.com/plugin/9212-flutter)

[2] [https://pub.dartlang.org/packages/flutter_redux](https://pub.dartlang.org/packages/flutter_redux)

[3] [https://github.com/flutter/flutter/issues/1150](https://github.com/flutter/flutter/issues/1150)

<comment><USER10> How is the integration of Flutter apps with the rest of the Android system/apps? Given that Flutter does not use the platform native widgets -- do Flutter apps look or behave different?

How difficult it is to use a Java library from Dart?

<comment><USER11> Disclaimer: I work on the Dart VM and Flutter engine

The Flutter team has done an amazing job recreating Material and Cupertino (iOS) widgets, and I honestly can't tell the difference. Also, platform specific behaviors (e.g., the scroll bounce on iOS) are also preserved.

If you haven't seen a Flutter app in the wild, I'd highly recommend checking out the Gallery application on Google Play ([https://play.google.com/store/apps/details?id=io.flutter.gal...](https://play.google.com/store/apps/details?id=io.flutter.gallery&hl=en)). Here you can see all the available widgets for each platform and even toggle between iOS and Android behaviors.

<comment><USER12> Given flutter can call down to iOS with plugins, and given that the apps are native, apparently, is it not possible to natively use the actual iOS widgets instead of reimplementing them?

<comment><USER13> For widgets it's not just calling to iOS that matters, but being able to render the widgets as part of the painting process, which Fluter does as a completely separate process from how iOS renders. So to integrate it, you'd need something involving compositing native views properly and yet propagating touch events to them, or rendering native views on top but doing the right masking, or ...

</comment></comment></comment></comment></comment><comment><USER14> AOT compiled to native code that uses the native instruction set - <USER3> interpreter/vm involved.

Uses custom rendering engine based on Skia.

Can write UX just once for all platforms if you don't mind fixing the widget set.

Custom widgets work on all supported platforms.

Can in theory be ported to Desktops also, assuming someone writes flutter engine bindings for Win/MacOS/Linux. If this occurs, then you will truly have a modern, cross-XP, write-once-run-anywhere, compile-to-pure-binary, reactive UX framework

Not a JS framework (tm)

<comment><USER15> "Can write UX just once for all platforms if you don't mind fixing the widget set."

Whenever something promises this, it usually only works kinda well on it's "home" or "main" platform, and runs crappy everywhere else.

<comment><USER16> Your statement isn't true of Qt or Java SWT or Java AWT. They don't have a main platform.

<comment><USER17> Unlike QT, SWT, or AWT, Flutter doesn't bind native widgets, but renders everything itself, so the way it works is more comparable to Swing though...

<comment><USER18> Swing is the perfect example that such approach simply doesn't work.

At the bare minimum, you need to use the native widgets on each OS.

It's baffling to me that Flutter didn't even learn this lesson from 20 years of agony with Swing.

<comment><USER19> Most interesting apps tend to use custom Android views, layouts and behaviors to create a unique, but consistent look and feel.

Flutter can do the same. There is not much difference, except that Flutter strives to do the unique part better.

On the Windows desktop your application must be coherent with other applications, since they share a big screen, or rather a workspace.

Either way you want to adhere to the design language of the OS, because it tends to work better than what you can come up with, and also provides familiarity. On Android you don't have to use the prebuilt widgets to adhere to the material design.

Flutter also comes with widgets that look and feel very similar to the Android and iOS ones, so you don't have to reinvent the whole wheel.

</comment></comment></comment></comment></comment></comment><comment><USER20> I really want to give my thanks to the Flutter team. Flutter allowed us to finally (and fairly quickly!) build a music production application on Android with feature parity to our iPhone offering. We're just three devs working on this in our spare time and I think without something like Flutter we'd never have been able to complete this.

We haven't hit release yet, but we're pretty confident we'll have our Android version out on the Play Store within about six weeks.

[https://tizemusic.com/](https://tizemusic.com/)

<comment><USER21> @bbreier this looks very interesting! Can you talk a bit more about how your overall _dev_ experience was, working on Flutter? How many times did you have to go _native_, where you had to create platform channels for features Flutter didn't already expose? How much code sharing, if any, were you able to achieve? Were there any corner cases you ran into?

Thanks, and good luck with the app!

<comment><USER22> Also very interested to hear the answer to this question

</comment></comment></comment><comment><AUTHOR> This seems like a clever move by Google to build a "write once, run anywhere" framework so that they can get some amount of apps running on their new mobile OS spike Fuschia. All they need to do is make Flutter compelling enough for Android developers to adopt it.

<comment><USER23> It's very clever. Except for Dart. It has an image problem among developpers. I don't know why but everyone I know seems to hate Dart (the only things worse than coding in Dart for my friends would be something like « writing amp pages in php using Atom »), so unless they can change that or support something like Typescript I'm not sure they'll attract a lot of developpers.

<comment><USER24> Why do people hate Dart? It looks like a nice language, has a well thought-out design. (I just looked at tutorials, havent written Dart code)

<comment><USER23> A while ago Google did try to ship Dart VM into Chrome (think AMP but for programming language). The language is indeed nice, it's a branding and communication issue, as it's often the case with Google.

<comment><USER25> Well, sorta. The Dart team tried to make it happen, and got a lot of pushback from the Chrome team. I don't think you can claim that Google tried to get it into Chrome.

</comment></comment></comment></comment></comment><comment><USER26> Sorry to do the picky thing and criticise a completely unrelated feature, but I wonder if we have, or are about to, reach peak "happy mandolin and animation" marketing videos. That is starting to feel old to me, early 2010s.

As for the actual content: they really buried the fact that it's based on Dart. Saying that only that it "also works on dart 2" It's almost as if they don't think that's a feature.

<comment><USER27> I keep hoping but year after year these videos are still here.

<comment><USER28> What alternative for a friendly intro would you suggest?

<comment><USER27> I wouldn't... I think people must like them?

</comment></comment></comment></comment><comment><USER29> So this is the problem with any cross-platform GUI toolkit: you have to make one of two choices:

1\. Implement the lowest common denominator between all your supported platforms so you miss out on key features on each platform; or

2\. Bypass native widgets so you end up with your own versions of everything where nothing quite behaves the same as native widgets do (ie Java Swing) and/or you incur a huge performance cost (ie Electron).

This is a touch hyperbolic but only a touch.

But consider this: Android uses garbage collection. iOS uses ref-counting. On a mobile platform, IMHO ref-counting is clearly superior and is a competitive avantage for iOS. GC leads to unpredictable behaviour, unpredictable resource usage and the inevitable stop-the-world GC pauses (at least I haven't seen a GC system yet that doesn't suffer from STW GC pauses to some degree).

On a server, this is less clearcut. The locking for ref counting itself can become hot but this just isn't really the case on an app on a phone.

It boggles my mind that years later (ARC came in in iOS 5), iOS still has this competitive advantage and not only does Android still not have it, nor does the Android-wannabe Fuchsia.

But back to Flutter, it uses Dart. I honestly don't see the point of Dart. Maybe it's just me but I don't want optional typing, or rather optional type hinting. I want static typing. The romance with dynamic typing over the last decade I think is on a downward trajectory with the rise of the likes of Go (really a better Python) and Rust.

<comment><USER30> > Maybe it's just me but I don't want optional typing, or rather optional type > hinting. I want static typing.

A ton of the community (and in particular teams using Dart at Google) felt the same way and the Dart team has been adapting the language to reflect that. Flutter uses Dart 2, which is statically and strongly typed.

> Garbage collection

GC is a nice value-add to the developer — most of us don't really want to spend a ton of time thinking about reference cycles etc. but as you note, it has the downside of being a potential source of jank. We mitigate this in Flutter by timing the work we do building frames and scheduling small GCs during idle time. Code here: [https://github.com/flutter/engine/blob/8109be8e21604df249b87...](https://github.com/flutter/engine/blob/8109be8e21604df249b87702b86e4b266ce44225/shell/common/animator.cc#L100)

<comment><USER31> That 100ms hard-coded value is interesting. What about 120fps devices?

<comment><USER31> Ah, ic, this is only allowed during idle time and nothing is getting painted.

</comment></comment></comment></comment><comment><USER32> So I took a good look at the docs and as a React Native developer, I do have some questions:

\- Is there code linting support in Visual Studio Code? I find that having a style guide, even if loosely enforced, helps a lot in learning how to structure code for long term maintainability.

\- The state of packages, in particular those that expose native SDKs, looks just like the early stages of native modules on RN. I know this is a beta, but what is the time frame for when all of these SDKs to mature? Or is this all on the community, in which case, I wouldn't be very convinced to use Flutter considering how long it took for good native modules to stabilize on React Native.

\- Why aren't the licensing requirement bits mentioned on the actual doc pages for Drawer and Material Components in Flutter? It's in the FAQ, but if they are required, putting them in the docs would be better: [https://flutter.io/faq/#how-can-i-determine-the-licenses- my-...](https://flutter.io/faq/#how-can-i-determine-the-licenses-my-flutter- application-needs-to-show)

\- Is there a roadmap that is more detailed than the milestones ([https://github.com/flutter/flutter/milestones](https://github.com/flutter/flutter/milestones))? With React Native, I know that support isn't going to suddenly dry up because it's an integral part of Facebook's current tech stack. So even if they don't focus on what I prioritize, at least I know it's being improved. With Google and their support reputation, I'm much more concerned about spending time to pick up Flutter & Dart only to have support taper off.

<comment><USER33> I can answer a few of these.

For Visual Studio Code support, the community has produced an extension: [https://marketplace.visualstudio.com/items?itemName=Dart- Cod...](https://marketplace.visualstudio.com/items?itemName=Dart-Code.dart- code)

Regarding packages, they're a combined effort between the Flutter team and external contributors. There are a bunch in [https://github.com/flutter/plugins](https://github.com/flutter/plugins), for example, with commits from both inside and outside Google.

<comment><USER32> The extension I saw in the docs, but I didn't see code linting as one of the features. Is there code linting included?

Thanks for the plugins link. Any idea what Google's stance is on supporting or expanding support of platform plugins? There's no issues for plugins so I can't tell how stable those packages are. So even if it's a combined effort, I feel weary repeating what the early stages of React Native felt like.

<comment><USER33> Linting is included with the extension (I think it's way down in the list of features on its page, but it're there). The flutter command line tool (included with the SDK) comes with a formatter, so it'd be insane not to hook into it.

Re: plugins, I hadn't noticed until just now that the instructions for the plugins repo say to file issues under the main one. There are plenty there, though. A search for "Firebase," though:

[https://github.com/flutter/flutter/issues?utf8=%E2%9C%93&q=f...](https://github.com/flutter/flutter/issues?utf8=%E2%9C%93&q=firebase)

turns up ~350 issues.

I can't speak for the team, but solid support for platform APIs is going to go a long way toward adoption, so I can't imagine it's being overlooked.

</comment></comment></comment></comment><comment><USER34> Mobile development is hard to get in. Maybe it's that I'm an outsider, but yet, on the second most popular platform it costs you an Apple computer and $100 for the IDE (IIRC), and on the other one the development experience is godawful (tools are slooow and janky, hard to integrate with your usual tooling, the program structure is incredibly complex, lots of XML, and then there's Java). Having looked around a bit, it seems to me that it should be easier to start with Flutter, the filesystem layout, the project configuration, the language, they seem managable, and I've seen some youtube videos where a guy only used VS Code and the Flutter command line. If I can just get going with Emacs and the Flutter's command line tool, that'd be awesome. Mobile app or game development seems to be a nice way to earn some money developing software solo, just from your laptop. And not having to deal with JavaScript is a nice way to spend more time for oneself. So definitely going to re-try this (tried it before but my impression was that I needed Android Studio, and that's a show stopper).

</comment><comment><USER35> As a backend developer I find flutter great. Recently created an app that uses Go compiled with gomobile as a backend for flutter UI. Widgets are great, Dart lang is easy to learn and understand :)

</comment><comment><USER36> I really wish that this was in Kotlin - a truly beautiful language which only won because of the community and not because of a large commercial enterprise.

Kotlin Native is already doing great.

If Flutter was in Kotlin, I'm willing to bet that it's adoption would be 100x of what it is right now. In addition, it gives devs a safe migration path from android to fuchsia.

<comment><USER37> Fuchsia is developed in Dart.

Where is Kotlin Native doing great?

Right now I wouldn't consider it for anything serious.

EDIT: Regarding Fuchsia, I only mean user space apps. The other layers are a mix of Rust, Go and C++ (C leftovers seem to be being migrated to C++).

<comment><USER38> > Fuchsia is developed in Dart.

I don't believe that's strictly true. Different parts of Fuchsia use different technologies. Flutter is (as far as I remember) the only UI framework for Fuchsia right now, so UI on Fuchsia is written in it (which uses Dart).

<comment><USER37> I mean the userspace apps.

If Google plays an Android/Android Things on Fuchsia there won't be much use of C++ for app developers.

</comment></comment></comment></comment><comment><USER39> Why should I use this instead of:

\- React Native

\- Vue.js + Cordova

\- Scala + JavaFX

\- Kotlin Native

\- (whatever I missed here)

?

I am in a mood to learn another language and framework; how would you persuade me to pick this one instead of alternatives?

<comment><USER40> Pretty well covered here: [https://hackernoon.com/whats-revolutionary-about- flutter-946...](https://hackernoon.com/whats-revolutionary-about- flutter-946915b09514)

<comment><USER41> Can you provide a summary of the convincing arguments from that article, in 1 or two sentences? I plan to read it myself, but I think the parent comment is relevant.

<comment><USER42> From the article:

\- The advantages of reactive views, with no JavaScript bridge

\- Fast, smooth, and predictable; code compiles AOT to native (ARM) code

\- The developer has full control over the widgets and layout

\- Comes with beautiful, customizable widgets

\- Great developer tools, with amazing hot reload

\- More performant, more compatibility, more fun

</comment></comment></comment></comment><comment><USER43> This feels like the Tennessee Valley Authority but for Dart. Just send people out there digging ditches in Dart to keep Dart's makers employed.

<comment><USER44> I laughed. Dart's low adoption but continued support by Google is programming's biggest mystery.

<comment><USER33> It's also a clear counterexample to the idea that Google always abandons projects.

<comment><USER45> its coming don't worry

</comment></comment></comment></comment><comment><USER46> My biggest hangup with a little project I wrote in React Native was using device storage. I didn't want my app to interact with APIs (which RN seems good at), and just wanted a little local DB. The whole `create-reactive- native-app` flow was pretty good up until I needed to have a local DB at which point I'd need to eject it and use various libraries in each of the ecosystems (or realm, I think).

What's the story with Flutter in that regard? Is there a nice cross-platform local DB interface that it provides? That would be a killer feature for me, if so.

<comment><USER47> Looks like it has sqlite support - [https://pub.dartlang.org/packages/sqflite](https://pub.dartlang.org/packages/sqflite)

</comment></comment><comment><USER48> How does Flutter fit in with PWAs? From a high level they both seem to do the same thing: cross-platform mobile application platforms.

<comment><USER49> I'd imagine it's mostly a performance thing. It also seems like Google is aiming to use this to help get more apps on Fuchsia as well. It may end up becoming the preferred method of making new apps on Android.

<comment><USER48> That would seem to indicate that--at least from Google's view--PWAs are a dead-end solution. I guess I can stop going through the PWA tutorials.

<comment><USER50> To me it indicates that they still differentiate between web and native - which I find reasonable, at least in performance terms.

PWAs will likely further rise in popularity and be very practical for good cross-platform support and ease of delivery - Flutter won't change that in the short term. In the long term, maybe it will.

</comment></comment></comment></comment><comment><USER51> I just discovered flutter today and made this post[0]. Good to see a beta release, pitching the alpha version of something to use in production is kinda difficult.

[0][https://news.ycombinator.com/item?id=16472139](https://news.ycombinator.com/item?id=16472139)

</comment><comment><USER52> So they ported dart to be used on mobile with a mobile app toolkit? It looks like the system is similar to react native but it uses dart instead of javascript and also compiles to native code. I wish you could use javascript because I really don't want to learn dart. I also don't really trust Google supporting yet another framework very long either. I wish they had a sample mobile app instead of just a video on the main page.

<comment><USER53> > I really don't want to learn dart

Literally half of programmers: "Ugh why can't everything be Javascript" Other half of programmers: "Ugh Javascript is the worst language in existence" /s

Given that javascript (esp on mobile) has a hard time reaching native performance, they presumably chose Dart because its design makes it immensely easier to target native iOS and Android without drastically augmenting JS to the point where it's no longer JS.

If there's a non-JS language that's easy to learn for a JS programmer, Dart (and I guess, TS) are it.

<comment><USER52> Sorry I didn't articulate my issue with Dart. The issue was not that I don't want to learn something that isn't javascript. The issue is that I don't want to learn a programming language who's only backer is Google. If dart had adoption outside of Google then I would have more incentive to learn it. So far it only looks like its used for internal google projects.

</comment></comment></comment><comment><USER54> This is good news. Hopefully it will gain more traction once it becomes stable.

</comment><comment><USER55> You will never convince me that laying out UI elements in code is better then building out an object graph in something like xml. UI views are just containers inside containers inside containers, and following complex nesting chains through code declarations is a nightmare.

<comment><USER56> The killer feature of building UI elements in code is that you can build up more complex widgets from simpler ones using composition. Flutter does this everywhere, which makes it super easy to modify or customize any widget, or to reuse widgets to build a new one.

You mention following complex nesting chains through code declarations. I understand what you are talking about, but the (awesome) Flutter tooling now has two views that make this far easier: the Widget Inspector, which lets you see and modify the widget tree at runtime (there was a talk on this at DartConf), and the new Outline view (just released a few days ago), which helps you play with the widget declarations in your code.

See [https://flutter.io/inspector/](https://flutter.io/inspector/) and [https://groups.google.com/forum/#!topic/flutter- dev/lKtTQ-45...](https://groups.google.com/forum/#!topic/flutter- dev/lKtTQ-45kc4) (for the outline view)

<comment><USER37> > The killer feature of building UI elements in code is that you can build up > more complex widgets from simpler ones using composition.

You can do this in XAML since 2006, and JSP since 2004.

<comment><USER57> Not sure why you're being downvoted. XAML definitely supports complex widget composition in markup. Since the XML is basically just describing an object graph, it's a more concise way of writing the equivalent imperative code:

        <Button>
            <StackPanel>
                <Image/>
                <TextBlock/>

        ...

        <Button>
            <Canvas>
                <Ellipse/>

although the Dart syntax makes this look similar, albeit a little more verbose, if you squint.

Full disclosure: I work at Microsoft.

</comment></comment></comment></comment><comment><USER58> I am really glad Flutter came out as beta and finally ReactNative got a good competitor, so maybe it will encourage both sides to improve itself and polish various (annoying) edges.

</comment><comment><USER59> I hope Google puts some effort towards building an easy way for developers to access maps through flutter. Right now the story doesn't seem very good.

Another place that seems lacking is photo/camera access.

Maps and Camera access are really table stakes for any cross-platform framework at this point. Many app concepts need location/maps and media access.

</comment><comment><USER60> This is the future of mobile development, and of googles new operating system Fuchsia, that will be replacing Chrome and Android on the long term.

The architecture of Flutter is superior to that of non-reactive based frameworks like Cocoa and Android widgets.

Try flutter, try the apps, and you will know why.

Note: This is all guess work.

</comment><comment><USER28> This reminds me of my experiences with Kivy and Cordova, etc.

The achilles heel of these projects are always vendor and community support if you want to build anything more than toys. Do they have the endurance to go the distance?

</comment><comment><USER61> I need to write a mobile app for iOS and Android which uses Bluetooth Low Energy and talks to an MQTT server. Would Flutter be a good choice to make a prototype for such an app?

</comment><comment><USER62> I made a small project with Flutter and found it intuitive and simple. Far more so than react native, and the end result is far nicer.

</comment><comment><USER63> Why flutter? what problem does it solve better than the existing solutions? Also, why dart? Why not Go or Kotlin?

Edit: Hmm, since I am getting downvoted, can someone please say what am I doing wrong here? Thanks. :D

<comment><USER56> There's an article that answers your question -- [https://hackernoon.com/whats-revolutionary-about- flutter-946...](https://hackernoon.com/whats-revolutionary-about- flutter-946915b09514)

<comment><USER63> That was a good article, thanks.

</comment></comment></comment><comment><USER64> Does it have any advantages over React Native?

<comment><USER14> AOT compiled to native code that uses the native instruction set - <USER3> interpreter/vm involved.

Uses custom rendering engine based on Skia.

Can write UX just once for all platforms if you don't mind fixing the widget set.

Custom widgets work on all supported platforms.

Can in theory be ported to Desktops also, assuming someone writes flutter engine bindings for Win/MacOS/Linux. If this occurs, then you will truly have a modern, cross-XP, write-once-run-anywhere, compile-to-pure-binary, reactive UX framework

<comment><USER43> What "theory" keeps React Native from being ported to desktops?

<comment><USER14> React Native is already ported to desktops but you need to write N times for N platforms. In flutter, you can write just once after choosing a widget set, assuming you don't mind the same widgets everywhere.

<comment><USER43> So it's like Xamarin -- there's UI for iOS, UI for Windows, UI for Android, but you can also use "Xamarin Forms" and have a similar appearance everywhere. But there's nothing stopping there from being a "React Forms" or whatever that does the same thing, is there?

<comment><USER65> > being a "React Forms" or whatever that does the same thing, is there?

Nothing stopping it, nope. I'm surprised there isn't something currently.

That said, it isn't so bad using different render functions for different platforms. The state management and event handling should be 100% consistent.

Besides, going all in on a single render engine limits you to creating special "holes" to utilize controls native to the platform. Im not sure if flutter supports this, but I doubt it.

<comment><USER66> > Nothing stopping it, nope. I'm surprised there isn't something currently.

There is - ironically, by the owners of Xamarin:

[https://microsoft.github.io/reactxp/](https://microsoft.github.io/reactxp/)

Hadn't heard of it practically at all since the initial announcement. It seems it's a _very_ small team: [https://github.com/Microsoft/reactxp/pulse](https://github.com/Microsoft/reactxp/pulse)

</comment></comment></comment></comment></comment></comment></comment><comment><USER67> Does flutter support RTL languages?

</comment><comment><USER68> Does it work with AngularJS1?

</comment><comment><USER69> how do you access native frameworks like AVFundation? is there any example?

<comment><USER33> How-to: [https://flutter.io/platform-channels/](https://flutter.io/platform- channels/)

Tons of real world examples: [https://github.com/flutter/plugins](https://github.com/flutter/plugins)

</comment></comment><comment><USER70> Can this work with typescript somehow?

<comment><USER71> No it's Dart, you'd have to transpile which would turn it into a bit of a clownshow unfortunately

<comment><USER70> How about typedart? j/k.

I really wish there was a way to pass type information into JS VM so that code could be optimized better.

</comment></comment></comment><comment><USER72> >High-velocity

>Hamilton

</comment><comment><USER73> Hey Google! Your Android IDE (full of feature taxes) is pulling this down! Did you forget Dart doesn't need a compiler, so there is no immediate use for an IDE? Please remove it from your setup and we'll talk!

<comment><USER74> If you want something lighter for Flutter, you can use VS Code with the Dart Code extension:

[https://marketplace.visualstudio.com/items?itemName=Dart- Cod...](https://marketplace.visualstudio.com/items?itemName=Dart-Code.dart- code)

(Disclaimer: I'm the author of the Dart Code plugin)

</comment></comment><comment><USER75> I thought dart was dead... like buried way down dead. Has dart improved? Are they eventually going to kill Android only dev?

</comment><comment><USER76> So what about Kotlin? I thought Google supported it as a first class citizen for Android development. And now that it looks like Kotlin is more popular than React-Native for mobile development, they add Dart2/Flutter.

<comment><USER37> Dart/Flutter was already presented at Google IO 2017, and is how Fuchsia userspace apps are developed.

As for yet another framework. Welcome to Google.

Android NDK alone has already been through 6 build systems, 3 public and 3 used at Google.

EDIT: 3 external were ndk-build, gradle experimental, cmake with gradle stable. The 3 internal, looking at AOSP and other projects, ndk-build, blaze and Soong.

<comment><USER45> out of curiosity have any idea why so many build systems? just flinging spaghetti at the wall until one is ideal? I mean I understand its good to rewrite software every so often but 6 in the timeframe of android ndk?

<comment><USER37> Some of them are internal mind you, things like Soong are only on the AOSP source code.

[https://android.googlesource.com/platform/build/soong/](https://android.googlesource.com/platform/build/soong/)

As for why, I guess reasons.

</comment></comment></comment></comment><comment><USER77> Unable to read the page on my phone.

iOS 10 / Safari / Private mode.

<comment><USER78> Works fine for me in iOS 11 / Safari / Private mode.</comment></comment>


Show HN: Tensor product analogy – functional currying - <AUTHOR> https://jwkennington.com/blog/tensor-product-for-programmers/ <comment><AUTHOR> I had to explain tensor products to several of my developer friends and realized that they found the rigorous approach somewhat obstructive. When I recast the subject in terms of functional programming (specifically, the pattern of currying), the group seemed to understand better.

Tensors are a "hot topic" in modern computing (AI, tensorflow, etc.), but it's surprising how many practicing computer scientists (or data scientists) think of tensors as "n-dimensional arrays" instead of "multilinear maps". Most of the modern mathematical theory emphasizes the latter viewpoint, though some texts (such as Goodfellow's Deep Learning) land in the middle. Goodfellow does adopt an unusual convention for Einstein summation, but that's a subject for a different post...

Thanks for reading. Let me know if there is anything in the post I might clarify!

<comment><USER2> One benefit of adopting the currying view is that you also introduce the Tensor-Hom adjunction (since currying is itself just the corresponding non- linear adjunction on the category Set).

That being said, understanding the universal property of tensor products is also fairly important.</comment></comment>


Introducing Amazon Virtual Private Cloud - <AUTHOR> http://aws.typepad.com/aws/2009/08/introducing-amazon-virtual-private-cloud-vpc.html

<comment><USER2> This seems like it's mostly aimed at the kind of corporate idiots that are obsessed with centralized firewalls and proxies and "application security firewalls", especially when they're packaged as a funny-colored 1U server with an awful web interface and a 100x markup.

It will be a great success.

<comment><USER3> Haha, the Redline EX3250 is an example of one of those 1U servers that can take a lot of load off your servers by doing all your SSL. It sold for $30,000 in 2003 - I bought one on EBay for $225 in 2007 and use it to run SSL for my site. It's amazing what people pay for "enterpriseyness."

</comment></comment><comment><USER4> I wonder if this is an effort to make it easier for corporate IT departments to run experiments with EC2, in hopes of eventually luring large datacenters on to the service. It seems like it would be vastly easier to get political cover for trying out a VPN-only service unreachable from the internet than the regular EC2 infrastructure.

</comment><comment><USER5> This feature is maybe the most important one since EC2 was launched. It makes cloud computing enterprise ready...

<comment><USER4> Can you explain what you mean by 'enterprise ready'?

<comment><USER5> It allows enterprises to easily and securely integrate servers that run in the cloud with their own internal infrastructure via a VPN. This fosters hybrid environments (internal IT + cloud in parallel) and thereby lowers the barriers for migrating IT services incrementally to cloud services. It takes away one of the most cited obstacles for the adoption of cloud computing in enterprise IT: security.

<comment><USER4> Thanks, I get confused sometimes by enterprise lingo.

My guess is the warm secure feeling will last until the new security tradeoffs of cloud computing become better understood a few months from now. But since so much is about perception, this is a clever move.

<comment><USER5> I agree that is by far not the end of the security discussion, especially, there is always that issue of trust towards the cloud provider itself. Do you trust Amazon's VPN, privacy mechanisms, etc. or do you prefer a third-party provider? Similar to: do you trust MS Firewall or the one of a third-party provider?

But I think it is more than only addressing perception - the alternative until today was building your own VPN by hand and dealing with all those dynamic IP addresses. Very awkward and error prone...

</comment></comment></comment></comment></comment><comment><USER6> I got all excited thinking they had made something I could install in my own data center. While nifty, this still doesn't allow me to properly protect my data (whole disk encryption, etc). I want a self-hosted private cloud.

<comment> a-priori <http://open.eucalyptus.com/>

<comment><USER7> And the competitor to this is a YC company, Virtualmin.

<comment><USER8> We're a co-opetitor to Eucalyptus, I think. Or something. We don't directly target the model of Eucalyptus, which seeks to exactly duplicate the AWS API on your own machines (a valid pursuit, I suppose, but not one we're interested in). We will very likely support Eucalyptus at some point (assuming customers want it; though no one has actually asked for it, so far; it would be relatively easy to add since we already support AWS), as Yet Another Virtualization Layer. We're agnostic about that stuff.

We have built our own (much simpler to use) API and GUI for building private clouds, but it doesn't seek to clone the AWS API in any way. Though it can use AWS as one type of virtual system to be managed (among many others; Xen, OpenVZ, Zones, and vservers, with KVM and VMWare on the TODO list). Where we're particularly strong is in delegation and resource sharing amongst many untrusted parties. We're trying to help people build AWS-style services and sell them or offer them to disparate divisions within a large company. It's still early yet in that plan, but we're speeding up on Cloudmin (our product in this space) now that we have several heavier users of the product.

Anyway, private clouds are definitely something a large number of huge companies want. Amazon has no good incentive for moving into that space, since there's so much room at the bottom where they're operating now, and there's still thousands of companies that _will_ move into the public cloud to one degree or another that have not done so yet. Actually, I guess if Amazon wanted a monopoly on the space, then they would have one good reason for moving into the space, but from everything Bezos has said on the subject, they don't actually want a monopoly or think they could maintain one. We'll see, I guess.

<comment><USER9> "private clouds are definitely something a large number of huge companies want. Amazon has no good incentive for moving into that space [...]"

Maybe not directly. A year ago Amazon participated in a $12M series B financing for Elastra, a major private cloud player. As far as Amazon is concerned, more private clouds means more hybrid clouds, which means a bigger pond for the every-growing AWS fish.

<comment><USER8> No argument here. We've found that the folks we're interacting with _do_ want to be able to overflow into AWS, as needed, and with data that is not sensitive.

I think Amazon is moving with astonishing efficiency in this space. If we ever find ourselves in competition with them, I'll probably sleep a little restlessly at night. They're certainly more sure-footed than almost anyone else in the space. They occasionally implement things in ways that are a little obtuse, but in general, they've executed extremely well, iterated rapidly (incredibly so for such a large company), and delivered good products before anyone else even realizes there's a need.

</comment></comment></comment></comment></comment></comment><comment><USER10> Wonder how this compares to skytap (www.skytap.com)?</comment>


Show HN: ci/cd with docker, node, aws and gitlab - <AUTHOR> http://james-leahy.com/posts/cicd/ <comment><AUTHOR> This is the first technical article that I've posted online.

It is a tutorial that will show you how to setup continuous integration/continuous deployment with docker, aws (elastic beanstalk), node and gitlab.

Hopefully someone finds it interesting.

<comment><USER2> Hey James, thank you for being such an incredible part of the GitLab community! Specifically, for taking the time to write about our product. We really appreciate sharing this with the rest of the community. Could you please reach out to us via email@example.com?</comment></comment>


Select vs. choose - <AUTHOR> http://inessential.com/2010/12/03/select_vs_choose

<comment><USER2> Waiter: Here is the wine list. Please let me know if you'd like any help with your wine selection. (later) Have you selected a wine?

This common example uses "select" (correctly) with a list of items on a menu.</comment>


Ask HN looking for a co-founder - <AUTHOR>

I'm working on a startup (That I've talked about here a couple of times.), and I'm trying to find a co-founder. I have two questions.
1. I live in a small town in northeast Colorado, is there anything I can do until I can get moved to Denver to start looking?
2. I'm blind, (Not totally, but for all intents and purposes I'm considered blind.) How important should this be when talking to a potential co-founder?
As always, any advice would be appreciated, Thank you. <comment><USER2> Is this for the online learning idea? What are you seeking in a cofounder (proficiency in a certain technology; background in education...)?

<comment><AUTHOR> Yes, I'm mainly looking for someone with marketing skills.</comment></comment>


NEW REPORT ON ANDroid - FEWER THAN 1% OF PHONES ARE POTENTIALLY AT RISK - <AUTHOR> http://www.fastcompany.com/3044608/new-report-on-android-security-finds-fewer-than-1-of-phones-are-potentially-at-risk

<comment><AUTHOR> USING ANONYMIZED DATA FROM 1 BILLION PHONES, GOOGLE HAS SET THE BAR FOR ANDROID SECURITY. WILL APPLE FOLLOW SUIT?

Google just released its 2014 Android Security Year in Review, an intensely data-driven report intended to bring transparency to the vulnerability of phones running on Android. Its findings: fewer than 0.15% of devices that only install from Google Play had a Potentially Harmful App (PHA)—apps that pose a threat to users or their data— installed. Overall, fewer than 1% of Android devices had a PHA installed in 2014. Apple, Microsoft, and Blackberry haven't released similar figures."

<comment><USER2> Same story in the opposing camp's echo chamber, opposite headlines: "OVER 10 MILLION ANDROID USERS INFECTED WITH MALWARE" "SIGNIFICANT ODDS OF MALWARE, EVEN WITHIN 'SAFE' GOOGLE PLAY"

The whole platform wars thing gets really tiresome</comment></comment>


Recursion and Tail Calls in Go - <AUTHOR> http://www.goinggo.net/2013/09/recursion-and-tail-calls-in-go_26.html <comment><USER2> > Recursion is great for algorithms that perform operations on data that can > benefit from using a stack, FILO (First In Last Out). It can be faster than > using loops and can make your code much simpler.

I can't think of a scenario where recursion results in a faster algorithm than an iterative form. Almost always recursion makes an algorithm simple to express and understand, while the iterative form is almost certainly more performant and the expense of a little more opacity.

I enjoyed reading all of the Go details even if I think that the takeaway should've been "write recursive algorithms in an iterative form if performance is a concern" (in Go).

<comment><USER3> Can't recursion do multithreading whereas iteration cannot?

<comment><USER4> It doesn't particularly matter. The loop:

      a, b = some input arrays of identical length
      c = the output array
      for(int i = 0; i < c.length; i++)
        c[i] = a[i]+b[i]

can be easily run in parallel, each iteration of the loop kernel is independent of every other iteration. And, with OpenMP a #pragma could make that loop run in parallel without any difficulty (long time since I've used it, forgotten the actual code needed to make it happen but it's easy).

      vector_sum([],[]) -> [];
      vector_sum([A|Atail],[B|Btail]) -> [A+B|vector_sum(Atail,Btail)]

(it's been a while since I erlanged, probably messed up the syntax)

Each iteration should be independent, but the way we've constructed it it's not easily transformed to run in parallel now. In fact, that's a bad construction because erlang _does_ have TCE and that recursion isn't in tail- call form.

EDIT: Also, iteration and recursion are transformable to each other. If you have a language with tail-call elimination, then recursive code with tail- calls should be equivalent to code using more conventional loop structures.

If no data needs to be retained between the recursive calls (consider this probably bad code):

      int[] vector_add(int[] A,B,C, int index) {
        if(index == C.length) return C;
        C[index] = A[index]+B[index];
        return vector_add(A,B,C,index++);
      }

assuming A,B, and C are all initialized correctly outside this call, it's fundamentally identical to (with TCE, actual assembly may not be the same without a bit more care taken in defining the function):

      int[] vector_add(int[] A,B,C) {
        for(int i = 0; i < C.length; i++)
          C[i] = A[i] + B[i];
        return C;
      }

That's a trivial transformation. Now, if we need to somehow retain some data (like an accumulator) it's not much harder:

      int factorial(int N) {
        int result = 1;
        for(int i = 1; i <= N; i++)
          result *= i;
        return result;
      }

      int factorial(int N, int result) {
        if(N = 0) return result;
        return factorial(N-1, result*N);
      }

call the second one as factorial(N, 1), you'd likely have a wrapper to abstract that out for any user so they only have to call factorial(N).

What if the recursion isn't a tail-call, how can we transform it? (bad factorial):

      int bad_factorial(N) {
        if (N == 0) return 1;
        return N * bad_factorial(N-1);
      }

Assuming we want to keep this stack, the equivalent code with a loop would be like:

      int bad_factorial(N) {
        int result = 1;
        Stack values = new Stack();
        for(; N > 0; N--)
          values.push(N);
        while(!values.isEmpty())
          result = values.pop();
        return result;
      }

That stack we've created replaces the program stack that was used implicitly in the recursive version. I won't guarantee the performance or assembly is identical (they won't be) but they're on the same order for both execution time and memory use.

<comment><USER3> Ahh, that makes sense. Thanks!</comment></comment></comment></comment>


Word Popularity Analysis for Congress - <AUTHOR> http://www.capitolwords.org

<comment><USER2> Did anyone see Technology, Science, or Education?</comment>


Show HN: A tool to convert Jupyter notebooks to beautiful blogs - <AUTHOR> https://github.com/hemanta212/blogger-cli <comment><USER2> Neat! Anyone working on projects to improve the share-ability, code review, version control, or web rendering of Jupyter notebooks, feel free to reach out to me when looking for an enthusiastic early user. Jupyter has been a game changer for my productivity as a data scientist, but I still struggle with something that seems as simple as "what's the best way to expose this to other people easily without having to set up a self-hosted nbviewer".

<comment><USER3> Is it tough to manually convert the md and use a CMS like Ghost or Hugo for website?

Alternatively, exporting HTML and publishing can also help right?

I'm curious why did you say so. Moreover did you check the recently released `voila` package that lets you publish Jupyter notebooks?

<comment><USER2> There are a bunch of ways that make it _possible_ to do all of this. What's really missing is a way to make it as easy as committing code to Github repo without having to do anything more than install a Github extension.

Right now, I do my work in a notebook, it's automatically converted to a Markdown file (for code review), and I use nbconvert to generate static html, which gets deployed to an internal docs site. I've also been tinkering with ReviewNB, which is trying to make notebook review look like code review, but it's separate from Github and is still fairly unpolished (but very promising!).

Ideally, the experience could be something like: * Install Github extension that offers a notebook review tab and automatically converts notebooks to a static HTML file that can be served from a url directly accessible from Github

I can think of a bunch of challenges involved in doing something like the above, but my experience working somewhere that offered a tool that allowed me to literally click one button within my notebook and have a shareable url that contained my notebook and the ability to comment line-by-line taught me that this massively unblocks data scientists, who will otherwise end up copy/pasting stuff into documents just to deliver things to partners faster.

<comment><USER4> > and is still fairly unpolished (but very promising!).

I'm all ears. Please write to me at email@example.com

I built ReviewNB and push improvements almost every single day :)

</comment></comment></comment></comment><comment><USER5> I have never understood why the "In[5]" and "Out[5]" in jupyter have to be so prominent, even in a output like this.

<comment><USER6> _5 is a magic variable with the value of the output from cell 5. _ refers to the last output. Super handy when working interactively.

<comment><USER7> Oh my god. I have used Jupyter notebooks for 7 years and never knew this. I just had to fire one up to verify -- and yep; exactly as described. How amazing! Thank you!

<comment><USER8> I believe the _5 syntax is specific to Jupyter, but in Python, the output of the last statement you execute is bound to _

For example, if you simply enter 4 into a Python REPL, printing _ will also print 4

It's really handy if you call a long statement in the REPL and forget to save the output to a variable

I wrote about it once if you'd like to see some better examples: [https://utf9k.net/blog/lost-python-results/](https://utf9k.net/blog/lost- python-results/)

</comment></comment></comment></comment><comment><USER9> Cool, but I would rather use a better supported static site generator with an ipynb plugin (ie, [https://github.com/danielfrg/pelican- ipynb](https://github.com/danielfrg/pelican-ipynb)) than a tool just for notebooks.

Especially because this looks like an nbconvert workflow under the hood.

<comment><AUTHOR> > Especially because this looks like an nbconvert workflow under the hood.

It is, however I convert it to the most basic html and add custom css and js to it. So that I can change it to whatever I want. I don't see any problem with that maybe you could point some out.

I didn't go with pelican(or any static gen) because the build times will be much slow later on as blogs increase [1] as this guy faced. I like to configure a lot of things manually and don't want the burden of static gen if that make sense to you. I just needed a converter.

1\. [https://nipunbatra.github.io/blog/2017/Jupyter-powered- blog....](https://nipunbatra.github.io/blog/2017/Jupyter-powered- blog.html#Other-fixes)

</comment></comment><comment><USER10> Nice. I have been using gitlab CI and a simple Python script to publish my notes (usually in markdown and Jupyter notebooks) to Gitlab pages. You can find the output on [http://avilay.gitlab.io/gyan](http://avilay.gitlab.io/gyan). And if you want to reuse the code you can find it in [https://gitlab.com/avilay/gyan/blob/master/publisher/publish...](https://gitlab.com/avilay/gyan/blob/master/publisher/publish.py). Will surely check out your stuff.

<comment><AUTHOR> I didn't find it responsive though. Maybe not your goal but the designs are similar. Similarly I think you can import nbconvert instead of just calling from subprocess.

</comment></comment><comment><USER11> Nice, have you looked into jupyter-themes? I've played with it a bit to make a similar notebooks-->static project and it's really great!

</comment><comment><USER12> I browsed the example link given at the GitHub site, and found this blog entry on lessons to tell your younger self. This post is amazing! All the advice rings true. Worth a read! [https://pykancha.github.io/test/2018/cs-phd- lessons.html](https://pykancha.github.io/test/2018/cs-phd-lessons.html)

<comment><AUTHOR> Here is original link: [https://nipunbatra.github.io/blog/2018/cs-phd- lessons.html](https://nipunbatra.github.io/blog/2018/cs-phd-lessons.html)

</comment></comment><comment><USER13> Offtopic; does anyone know a tool that can turn a directory of source code into a nicely formatted PDF/PS? So with syntax highlighting etc based on the file you have and chapter index based on directory structure for instance?

<comment><USER14> Pandoc? I haven't used it in a while though.

</comment></comment><comment><USER15> Did something go wrong here?

[https://pykancha.github.io/test/2019/selenium_p1.html](https://pykancha.github.io/test/2019/selenium_p1.html)

<comment><AUTHOR> Nope. It was to test my native language for unicode support.</comment></comment>


Twitter Inventor Jack Dorsey Is Working For Twitter Again - <AUTHOR> http://www.businessinsider.com/jack-is-back-twitter-investor-jack-dorsey-is-working-for-twitter-again-2010-11

<comment><USER2> From the article:

 _> Some sources say Jack is back on new Twitter CEO Dick Costolo's request, and that Ev isn't thrilled about it._

Interesting.</comment>


Ask HN: Need help choosing a database for a local-remote multi master sync - <AUTHOR> Hi all,
I'm on a mission to find a the right database for a big project I've been working on for a while. As of right now, I'm on a CouchDB (Cloudant) NoSQL database in the cloud while using PouchDB on Asyncstorage using a library in React Native. It's a bit buggy for me right now.
I was wondering if anyone has done something like my below use case and could give me some guidance on what I should choose. My biggest issue is wrapping my head around how to do these multi-master type syncing requirements I have. Any help or guidance would be greatly appreciated.
My use case is as follows:
Master Database — This is in the cloud. And is the complete repository where all documents are stored.
Local intranet(s) — We install a local database on a linux machine on worksites. They periodically have access to the internet, which is how they will grab and send data from the mater database; but for the most part, they will be offline but will be connected to a local wifi network that devices can access. It should be noted that I only grab specific documents from the cloud. Time based and maybe like 50 other documents that are based on type. And then obviously any documents that are added to the database, we push to the master manually when we have internet.
Device(s) — During an online set up with the master database or via the local intranet, there are about 50 documents that are necessary to run this application that we need to grab. This is where all the documents are created. Depending on worksite, we want to make live queries to the master database or live queries with the local intranet. Whenever a document is created, we want to push this to either one of those so all devices can share the same information. Whether it be device->local intranet->cloud or device->cloud, the documents that are created need to get off the device and to the master. Once they are on the local intranet, we are goodie, or once they are on the cloud.
I should note that we never update a document atm to avoid conflicts and to keep an audit trial. <comment><USER2> Try [https://www.2ndquadrant.com/en/resources/postgres- bdr-2ndqua...](https://www.2ndquadrant.com/en/resources/postgres- bdr-2ndquadrant/)

<comment><USER3> It is not really multi-master sync, it is master-slave sync (they call slaves as shadow-masters from some (marketing?) reason).</comment></comment>


Never Launch, Just Iterate - <AUTHOR> http://www.marketing.fm/2009/11/17/never-launch-just-iterate/

<comment><USER2> That's actually _really_ good advice. If you do use the press and other media be prepared for a let-down, all that stuff is only a momentary impulse, and unless you are extremely sticky you are not going to get much out of it.

Satisfied, returning users is the only way to really grow a business, it's easy to see why:

Even if everybody in the world came by tomorrow but nobody got stuck you'd be looking at 0 traffic on Friday next week, but if instead of that you'd have 1000 new users each day of which 10% got stuck you'd have _at least_ 2,000 visitors per day by Friday next week.

Now 2,000 visitors per day doesn't sound like it is much but depending on the product you might already be in the 'black' at that level. And if not, wait 90 days...

In practice it is a lot harder to get people to come again to your site than it is to get random individuals to come just once.

I remember coming across google the first time and instantly changing my homepage from 'altavista' to 'google'.

That's all it took, it simply worked and worked so much better that there would have been no reason to draw out the switching process.

<comment><USER3> How exactly do you plan on getting 1,000 new visitors every day, without a big media blitz for them to start hearing about your site? Sure you could buy ads, but you'll probably end up spending a thousand bucks per day just to get that 1,000 users.

And if you want 1,000 new people per day organically, you pretty much need 200-300K users for them to tell their friends about you.

A big media launch will put you on the map, sure only a tiny portion of users will stick around, but those few will give you that starting base to jump off from.

I don't see why that 10% stickiness you talk about, wouldn't also work during a launch. Sure you'll probably get a lot more lookie loos, but surely you'll reach a wider audience.

I'm actually doing a "launch" tomorrow, Hopefully I'll get some coverage, and if it's nothing but lookie loos, I can always go to doing the X users per day thing.

<comment><USER2> Give me your URL and I'll get you some links.

As for 1,000 people per day costing you a thousand bucks, you're doing something wrong there. 30K per month gets you at least half a million uniques per month in a competitive market, but you'll have to do your own 'buys', not go through a middle man.

A big media launch will get you most likely about 10 to 15,000 users and you'll drop to about 100 or so after one week. You don't have to believe me of course, but I've been there and done that several times now, the pattern for me so far has been fairly consistent.

People that come from a newsfeed are usually not actively looking for what you are offering just moderately curious.

The time you get them to 'stick' is when they are really in need of what you have to offer.

<comment><USER3> awesome, thanks! it's <http://styleguidance.com> :) I've had very good response from the alpha for it, and everyone seems to love it.

I'm going by the rate of return on ads I've seen in the past. Sure you get a ton of clicks, but only a tiny portion actually registers. Way below that 10% you've talked about.

No I trust you, I had a launch similar like that with another site. Had 60K the first two days. 20K on day 3. Then it slowly dwindled down to 1000 users a day. Those seem pretty loyal, but the problem was that it was a content site, that was generated entirely by me, and it wasn't worth focusing all my energy on something that brought in 2-3 bucks a day.

<comment><USER2> Ok, one link is up, let's see if you can 'catch' some of these visitors, will do another one on a different site.

The text I gave the link is: "If you (or your significant other) want to look your best"

If you want a different text let me know.

Ads are imho a waste of money unless you have a direct track between click and sale and you can measure very accurately which dollars spent give you how much worth of income.

<comment><USER3> awesome thanks! yeah that text should work.

Agree fully on the ads, the only reason I spent any money, was because I had some facebook and adwords credits. And since I'm not even running any ads now(don't want to scare off users), there is no X in ads = X new subscriptions.

Oh btw, I have the url fixer plugin for firefox, and it "fixed" your site to www.com, happened like 3 times before I realized what was going on, you should email that developer and tell him to whitelist your exact url. If that works, you'll get a ton of extra traffic.

The guy behind that plugin is <http://www.chrisfinke.com/>

<comment><USER2> Thanks for that heads up, I never realized that, I sent him an email.

edit: ok, second link is also up, together that should get you about 3.5M exposures per month, I'm really curious what it will do for you.

<comment><USER3> no problem, good luck with that.

Actually I just checked out and www.com appears to be a domain squatter(although he sells www.com email addresses, but there is no site), maybe you could even convince him to change www.com to ww.com

<comment><USER2> I tried buying the domain of that guy years ago, he's not selling.

[envy] It is probably the best ROI anybody ever made. I wouldn't be selling if I were in his shoes either, he gets 150K uniques daily on that domain without lifting a finger. [/envy]

<comment><USER4> It can't be -that- great. It's all junk traffic, so the CPMs probably suck. My friend owns netflicks.com which redirects to Netflix with a referral link and makes a bit more than www.com probably does.

<comment><USER2> At a conservative 1ct per click we're talking 1500 dollars per day here.

I'm not sure what your definition of 'not all that great is'.

As for your friend, he could lose that domain in a heartbeat if netflix set their mind to it.

<comment><USER4> I think your math is off. 150k daily uniques, at a conservative $0.01 CPM is about $1.5 a day.

<comment><USER2> Sorry for not being more clear. If you had to go and _buy_ that kind of traffic you'd end up paying $1500 per day, that is its value.

You can probably sell it for some multiple of that because 1ct per click is ridiculously low.

So we're talking about at least half a million dollars per year here and probably substantially more, 100% pure profit, near 0 expenses.

Here is a sample of the data of such a site:

<http://ww.com/adsense.png> , these pages have three adsense tags on them, two with pretty good conversion, one a lot less (but still 3x better than the 'overal average' of all adsense tags that I run.

21,500 euros is roughly 30,000 dollars, 3 million impressions is also roughly 3 million uniques on sites like this, so figure dividide by 20 to get to 150K uniques, which is just about 1500 dollars per day.

And that's _just_ adsense, you can bet that people that live of this stuff tend to put a few more tags on those pages.

The CTRs are ridiculously high because the user doesn't have much choice, they can either click an 'ad' or click 'back'.

Not a very honorable business model though, but then again, would you say no to a free $0.5M per year ?

</comment></comment></comment></comment></comment></comment></comment></comment></comment></comment></comment></comment></comment><comment><USER5> Clearly not all businesses lend themselves to iterating over time. For example, if you started a restaurant and you opened it before you were able to make good food, then your initial reviews would be bad so you'd crash and burn.

Rather than starting with the statement "never launch, just iterate" it would be better to start with the following question:

"Should I start a business that lends itself to iteration?"

That's an interesting question that's worth discussing. But as it stands this post is the wrong answer to the wrong question. (Which also shows how you can often catch sloppy thinking by making explicit the question that a statement is answering, and diffing that with the question you should be asking.)

edit: I think the actual answer is that you should choose to start a business that lends itself to iteration, but that's different than the advice given. It's another case where the given advice is close enough to the truth that it tends to work, but the underlying rule is still wrong.

<comment><USER6> _if you started a restaurant and you opened it before you were able to make good food, then your initial reviews would be bad so you'd crash and burn_

At least one restaurant opened in your city last week. Of the set of restaurants which opened in your city last week, one of them is last in the alphabet. Without checking either what restaurants opened last week or what the reviews say about them, what did the reviews say about that restaurant?

You should be so lucky as to have everyone know how bad you are.

<comment><USER5> "You should be so lucky as to have everyone know how bad you are."

I don't know any of the restaurants that opened last week, because I get my information about restaurants from restaurant early adopters and reviewers. This is how most people get their information about restaurants. That's why it makes sense for restaurants to follow Geoffrey Moore's advice of using the "bowling alley strategy" from Crossing the Chasm.

If you open a restaurant, you know in advance that you need to have a strategy to get restaurant early adopters in the door. And you also know that restaurant early adopters are the kind of people, by definition, who don't go back to the same place twice if it isn't very good.

Basically, it's only luck if you're successful without knowing this and having a plan to deal with it. And counting on this happening is a poor backup plan at best.

</comment></comment></comment><comment><USER7> Not in total agreement here.

The web was just a tad simpler over a decade ago when Google 'launched' initially. In fact a lot of the web's titans like Ebay, Paypal, Google, Amazon etc.. were 'launched' during a different era if you will... It was called the 90s. I'm not so sure the same rules apply today. One should at least consider that things have changed in this regard.

Every other product Google's come out with since then was 'launched' in what we'd consider the 'traditional' way. Gmail was invites, Wave is invites.. Maps was released with a lot of fanfare.

What I do agree with is that immediate or front page media attention after launch is not indicative of the app's future success. In fact it seems the more hype things have in the beginning the less staying power they seem to have in the long run but I suppose it can go both ways and there is no one rule..

<comment><USER8> Couldn't agree with you more. I agree with "release-early-iterate-often" however the notion of "never launch, just iterate" is bad advice IMO. This is also one of the few times I was surprised that more HN readers didn't poke holes in this blog post, but I think that's likely attributed to hacker ego in regard to "marketing" vs "engineering".

A few thousands visitors does NOT mean you're doing things right, in fact it _could be_ reinforcing poor judgement and a bad product. I've seen this happen countless times by founders who didn't know when to stop drinking their own kool-aid and meaningfully evaluate product holes because a handful of visitors swore it was the best thing since slice bread.

</comment></comment><comment><USER9> I don't see how launching and iterating are mutually exclusive.

</comment><comment><USER10> I appreciate this recommendation.

"Thank you, you love me, you really love me!" \- The Mask</comment>


Ask HN: Why are there so many bad developers? - <AUTHOR>

As someone who runs a software development consultancy I'm constantly talking to potential new clients.
It seems like 9 times out of 10 the potential client has had a really bad experience with another developer at some point... overcharged and under-delivered, non-working code, etc etc.
What's the root cause here? All these bad apples out there make my job a lot harder. <comment><USER2> Several reasons. Here are are the ones I can quickly think of:

1\. Lots of money for a product that customers can't _really_ inspect before paying. 2\. Same as #1, but simpler: lots of money. 3\. The customer. Feature- creep and a lack of vision can really dismantle a project in it's nascent stages. I've seen many a project fall victim to this. 4\. Lack of testing. This is usually caused by #5 and #6 below. 5\. Deadlines + customer's constantly changing scope can == bad code (at times). 6\. Like @coderdude said, the field itself (and it's workers) are generally immature (and therefore haven't learned best business practices - or best practices at all, for that matter). 7\. Web DESIGNERS != Web DEVELOPERS. Many, many customers don't know this (you'd be surprised).

</comment><comment><USER3> Potential Clients who are highly satisfied with another developer are much less likely to call you. I suspect there may be some sample bias.

<comment><AUTHOR> this is probably true to some extent

</comment></comment><comment><USER4> (This comment is focused mainly on web developers.)

It's a young and immature field. The clients are usually ignorant of the requirements and the level of quality to expect. This breeds a lot of half-ass developers and snake oil salesmen. I've personally known a few people who called themselves "web designers" but the work they create is God awful. Get- rich-quick types tend to want to jump on board to milk money from people. Web development is a great field for those kind of people. SEO is another.

<comment><USER5> Actually, I think the field is pretty mature at this point. I think it's more an issue of that fact that the barrier to entry is so low and that if someone has a hard time identifying a bad developer, they'll have a hard time identifying a good one too.

<comment><USER4> I'm framing that statement in perspective to almost all other imaginable fields of work. I'll concede that it may not be the cause for all the bad developers -- low barrier to entry seems like a much more likely cause, but I do not believe that this field has matured yet. Almost no one on the planet was selling web development services just 18 years ago, so it stands to reason that the field is not very mature yet. At least in my opinion.

</comment></comment></comment><comment><USER6> Or making your job easier... with so many bad apples, isn't it easier to stand above the rest?

<comment><AUTHOR> I suppose you could argue that... in my experience, no matter how successful your portfolio, potential clients that don't really understand the work/skill involved still easily get stuck at price

<comment><USER6> Your portfolio on velocis.us looks impressive. How much do you charge your clients?

<comment><AUTHOR> we generally charge and hourly rate that is a bit below market price (in comparison to other shops I know, and individual ruby devs)

:-)</comment></comment></comment></comment>


C Is Manly, Python Is for N00bs:How False Stereotypes Turn into Technical Truths - <AUTHOR> http://lambda-the-ultimate.org/node/5314 <comment><USER2> I started with C (and got pretty good at writing some cryptography in it), then studied Perl (a bit), then Python (2.6 to 2.7), then PHP (5.4 to 5.6) and now I'm totally into JavaScript and CoffeeScript.

Am I a n00b?

Just don't pay any attention to some pseudo-elitist old farts that try to tell you what's Ъ (true) and what's !Ъ (false). Do the things you, not others, consider awesome in the first place. Don't catch along with the progress, move the progress yourself.

And you'll just watch and laugh how others will try to build an app in 2 months in "manly" C that you can build in a week in "unmanly" Python or CoffeeScript.

Not everyone must target microcontrollers, cryptography or system kernels these days. In other fields, C appears as a pretty inefficient approach. Even console, let alone GUI, text editors are built in Node.js now - see Slap and Atom for an example. Are Slap or Atom developers n00bs? I don't think so.</comment>


Here Is Today (2013) - <AUTHOR> http://hereistoday.com/ <comment><AUTHOR> Came across this today (no pun intended).

Thought it was worth a revisit given everything going on.

Previous discussion: [https://news.ycombinator.com/item?id=5620893](https://news.ycombinator.com/item?id=5620893)</comment>


My dev super power is "I can build anything" so what the heck should I build? - <AUTHOR> https://www.dylanwilson.net/my-dev-super-power-is-i-can-build-anything-so-what-the-heck-should-i-build/ <comment><USER2> I don't have anything substantial to say for this blog post, sorry, except maybe a generic "scratch your own itch" and "continue scratching them until you find one that other people too have" sort of a thing. I guess you already know that, and you're looking for or thinking aloud about more specific advice.

But anyways, after reading this post I clicked around and read your other post. I found that useful, so wanted to say thanks! I especially found it useful how you separated market-fit from founder-fit, I'd not quite cleanly separated them that way before.

Also, while I'm sure it was very frustrating, but I wouldn't count it as failure: if there was a straight path to "success" (whatever that means to someone), then everyone would be taking it. Keep building, and best of luck!</comment>