This is Mises Weekends with your host, Jeff Deist. Ladies and gentlemen, welcome to Mises Weekends. As you can see, our guest is someone who's joined us before Dan de McAdams and the Ron Paul Institute for Peace and Prosperity. Today's actually a show we had not planned. It's Friday the 13th. We had a different show in the can, but because of events this week with Donald Trump tweeting about a potential attack on Syria, we felt we had to address the elephant in the room. For those who hadn't seen it, the Mises Institute put out a statement on Thursday at our website this week from the editors against war in Syria. It's actually got some great quotes from various economists, including Ludwig von Mises and Murray Rothbard about the depravity of war. You think generally we do our show about economics. And Daniel, in a certain sense, war is almost outside of economics because we're no longer dealing with people in voluntary ways. We're dealing with them via force. So in that sense, war is an extension of politics. And it's outside of economics. But that doesn't mean people don't make money off of it. So talk about Trump's change of heart. It feels like he's been captured just a week ago. He was talking about getting out of Syria. Now we're looking at John Bolton at NSA, Mike Pompeo at State, and bombs away. What do you think's happened? Yeah, I think that probably was his instinct. And that's certainly what he promised on the campaign trail that we shouldn't be staying in these places forever. If you look back at his tweets from 2013 and on, you see all these, Ron Paul was right. We shouldn't have bothered in Afghanistan. We got to get out of Syria.  So he has a paper trail of tweets. And I think his instincts led him to say that. When he was speaking before that audience in Ohio, which is a good audience for that kind of thing. Hey, our troops belong at home. We should bring them back home. A lot of cheers. But then the neocons did have a freak out. They went nuts.  You can't do this. And so lo and behold, less than a week later, there is this amazing chemical attack in Douma that has forced him to do a complete 180. I'm sure that's entirely coincidental. But as you say, a couple of days ago, he woke up and tweeted in a way that shocked the world because it really told the Russians, bombs are coming your way, essentially. And I think he's had to try to walk it back over the past 24 hours. But the marker was really laid down with that tweet. Give us a little bit of the history and background here. As you well know, US Fed was after Assad's father. They've been after Assad even prior to the so-called 2011 uprising in the Arab Spring. Why does the West and Israel, why do they hate Assad, and what's driving their monomaniacal desire to get rid of him? Well, there is a pattern of US intervention in Syria. As a matter of fact, the US was involved in regime change there decades ago. I think it was even before the 53 Iran regime change. So the US has been involved in it. There was this 2006 cable that was leaked by WikiLeaks, that was written by one of the staff members at the embassy in Damascus, who outlined in very great detail what it would take to overthrow the government of Assad. And really, they followed that pattern. They talked about radicalizing Islamists and all these sorts of things. And that's pretty much the pattern they followed. So there is, for some reason, US foreign policy has been to overthrow secular authoritarian figures in the Arab world. We saw it with Saddam Hussein. We saw it with Muammar Gaddafi. And the results have been universally pretty bad. So here we go again, trying to do the same thing in Syria to overthrow a Syrian government that's led by a minority in Al-Awwait. But the army itself is actually majority Sunni, which most people don't realize. But basically, here we go again. The neocons were not successful under Obama. He was able to resist, although he certainly, the idea that there was inaction is not correct. Because what he did was basically an Eisenhower under Dulles. He basically said, OK, CIA, have at it, man. Do whatever you need to do to overthrow this guy, but I don't want to invade. So we've been very active. And unfortunately, as Donald Trump is increasingly neoconized, i.e. his cabinet, et cetera, I think he's gone back to that direction. Certainly, that's what it seems like from here. But I just want to clarify, you're disputing this right-wing notion that Obama dropped the ball with Syria and that he should have been more active in dealing with Assad during his eight years. It's the same canard that they used with Iraq. Everything would have been peachy-keen there if that liberal Muslim Obama had not pulled us out.  They never looked to the antecedent if the antecedent suggests that non-interventionism would be the right cure. But no, Obama was very active. And in fact, there was an absurd point, and Dr. Paul and I did a show on it, where CIA-backed troops were fighting Pentagon-backed troops inside Syria. So it almost became sort of a comedy of errors, except it wasn't funny because so many people have died in essentially what's a proxy war to overthrow the Syrian government. Well, as you know, we're still hearing that George Bush Sr. should have killed Saddam Hussein in 1991 or 92, and we'd all be fine today. I just want to talk about this disconnect between Washington and the US population. I think with social media, with traditional media, and just with the passage of time, I don't think there's any constituency out there in the country, or at least not much of one, for an actual boots on the ground war in Syria. I think the American people have learned at least some dim lessons from Libya and Iraq and blowing things up. How do you explain why unpopular wars continue to have a constituency in Washington? And I don't just mean in the standard sense of the military-industrial complex, but how does support for these wars endure when they're unpopular at home? Well, I think, you know, there's a lot of psychological manipulation going on. You know, we've seen it over and over, the pattern continues. You remember in the run-up to the first Iraq war, where you had secretly the daughter of the Kuwaiti ambassador to Washington appearing before Tom Lentos in the House for the Ferris Committee talking about babies being thrown from incubators. All a total pack of lies, but it plays on emotions. I think the poor propagandists understand this, that you turn a basic human instinct, which is empathy, our feeling of empathy for humanity, you turn that into something that actually destroys humanity. You turn the empathy that we would have for what appears to be babies being harmed, children being hurt or killed, and you turn that into a sort of a murderous instinct demanding that we go kill someone to make up for it. And I think that's a psychological manipulation that mobilizes the population to go from being their natural instinct, which is to oppose war, to say, well, normally I'm opposed, but when I see those pictures of those kids, I say, we gotta have bombs away. Do you think this latest gas attack, supposed gas attack a few days ago, do you think the story is a lie? I think it's, certainly there's no evidence that it's truth. I think we have seen false flags that have been committed by these so-called white helmets. Remember the white helmets are the only source of documentary evidence that this attack took place. Who are the white helmets? Well, they were created by a British intelligence officer, James de Morriere, and they've been funded by the United States USAID and the UK foreign office to the tune of about $100 million. So these are not just a spontaneous group of people that run in, Russian helping people. They have their cameras ready. They make propaganda videos and this is the sole source of information on what happened there. Why would they do this? Because they have been very active with the rebels. They've been involved with the rebels from the beginning. They're pro-rebel, they're pro-regime change. And the thing is, Jeff, I don't know what happened there but I don't feel so bad that I don't know because just yesterday James Mattis was before Congress and he said, I don't know what happened either. We're just, we're trying to figure out what happened. I believe that he did it, but we don't have the evidence. So nobody really knows except the perpetrators at this point, what happened. That's when you go into motives. Military commanders talk about second and third order effects. Let's say the United States and other Western governments start launching a bunch of serious missiles into Syria and really do destabilize or even take out Assad. What follows? What happens next? We've seen this time and time again, we break the egg and then we end up in a country for 15, 20, 30, 50 years in Korea. Well, I think before that happens and let me just say before that, but I think what I'm about to say has been bolstered by the meeting last night in the White House, the president's cabinet met. But where the secretary of defense, Jim Mattis, told the rest of them, we don't know what's going to happen. We don't know how to stop this escalation. He also said it to Congress. So to answer your question, I would say before we get to the point where they are destabilized, to the point where Assad goes, I believe very strongly there will be a Russian retaliation and I believe that James Mattis, the secretary of defense, very strongly believes that there will be a Russian military retaliation. The US military has been on this hotline to watch Russian counterparts. So they do have information. And I think that Mattis has concluded that the Russians will respond while they sink a couple of ships. Well, something happened to the 2000 troops that are illegally in Northeastern Syria. I don't know what happens, but the threat of nuclear war I think would come first before anything, any talk about Assad going. But in terms of whether he was destabilized and overthrown, there simply is no one to replace him that's not a radical Islamist at this point. So we're replaying the scenario, Libya, Iraq over and over again. Well, you and I were both working for Dr. Paul in Washington in the early 2000s, 01, 04 when the Afghanistan-Iraq Wars began. But what feels different here is of course the Russians have a much more direct role.  I mean, Brinksmanship with Russia? We're awfully soft in this country. And I'm not sure people really understand what it means to poke a nuclear power. Yeah, I think it came to, I think President Trump's tweet focused a lot of Americans on this possibility. And I think the Russians who tend to not block when it comes to these things, they're not bombastic. They're actually rather doer when it comes to talking about these things. I think the fact that they were explicit, you know, the Russian ambassador to Lebanon told Al-Manour television that Russia will not only target the missiles that are incoming, but target their launchers, which would of course be the USS Donald Cook, among other things. So I think Americans focus now and realize that this is a serious thing. Everything that I've seen points to the fact that the White House switchboard has been absolutely jammed. So there's a suggestion, I've read it elsewhere, that he's hearing a lot from people and that doesn't necessarily change his view, but they're hearing a lot from people that do not want this war. Well, what's so frightening to me, Daniel, is that the mainstream media and even his enemies, his progressive enemies, and even his traditional GOP enemies pat him on the back and tell him he's acting presidential when he surrounds himself with people like Bolton and threatens war with Russia of all places. I guess the last question I have for you is, do you think we're any better organizer prepared than we were 15 years ago when the United States invaded Iraq? Is there any way for people to work together and try to avoid or at least minimize this war in using social media, using awareness in ways we didn't have in 2003 when we invaded Iraq? I think so, and we mentioned this on a recent Liberty report, and I think Nassim Nicholas Taleb talks about Twitter being an old-fashioned community, a billboard, a postboard where people get together and talk as a sort of a community. And I think that is the case, to a degree, for better or for worse, because I think social media is manipulated by outside interests. However, it is easier to mobilize. You remember how it was back in 2002 when we really didn't have this kind of ability to talk back, ability to send messages. We had to sit there listening to Judith Miller write lie after lie day after day with no way for it. So I think we are able to mobilize, but I also think that the bad guys are able to manipulate social media and turn it into tools of psychological operations as well. Well, ladies and gentlemen, that's all the time we've got. You need to be following Ron Paul Institute at RonPaulInstitute.org, follow them on Twitter, follow Daniel McAdams on Twitter, and you will know everything you need to know about what's going on. You'll get a lot of inside information you won't get, obviously, from our mainstream media. We hope that this thing doesn't blow up in our faces, that it doesn't escalate, and that somehow Trump's better angels can sit on his shoulders this weekend. But it remains to be seen. Daniel, thanks so much for your time on short notice. Ladies and gentlemen, have a great weekend. Subscribe to Mises Weekends via iTunes U, Stitcher, and SoundCloud, or listen on Mises.org and YouTube.


Hello, everyone, and welcome back to theCUBE's live coverage of UiPath Forward 6. I am your host, Rebecca Knight, along with my co-host, Lisa Martin. We are joined by two guests for this segment. We have Alan Pellsharp. He is the founder of Deep Analysis. Welcome, Alan. Thank you. And Luke Palamara, VP AI product development at UiPath. Hello. Thank you so much for coming on. Thanks for having us. So we're going to be talking about applying AI to the enterprise, and Alan, you literally wrote the book on this topic, Practical Art Diffusion of Intelligence and Enterprise Playbook. Why don't you start by giving our viewers the lay of the land and where you see the current state of the market in relation to AI, applied AI? Well, first of all, I wrote a book. There are others, but yeah, it's an interesting thing.  It's been around a long time, but the last few years it's become just so much more accessible, and frankly, a lot smarter than it was before. And so people are still sort of thrashing around a little bit trying to figure out what to do. I think in very, very practical terms, there's still a world out there that thinks this is for people with advanced math, data science, and actually it's not. It's incredibly accessible now. So we're in the early phases of figuring out what to do with it, and some of those things are very basic, undertaking administrative tasks that were previously manual. It's not very exciting, but it saves a heck of a lot of money, and it saves a lot of headaches, right? So hopefully in things like insurance, in healthcare, in customer service, just making life easier for everybody. There's many more complex and fantastic and amazing things, but those are the things in business that we're first encountering, and that's actually pretty cool. Yeah, yeah, and you said that a lot of people are still reticent or skeptical. They just haven't tinkered with it. As you said, we have this idea that it's for experts, for people who are good at this stuff. Yeah, and in truth, it is for experts. It's very complicated stuff, right? But just a few years ago, essentially you were building your own AI, it's not the case anymore, right? You come to a company like UiPath or whoever. They've already built it for you. So there's that element to it, and I don't know if it's about skepticism. I think it's just, we don't know where to start. This sounds clever, this sounds great, but where would we start with this in our organization? There is a secondary challenge that it's a cliche, but it's a truth, garbage in, garbage out, right? So if your data's pile of junk, it ain't going to work too well. So there are some very, very, very practical to use that term yet again. Challenges for organizations, but hey, it's there, you can use it, and if you're prepared to roll your sleeves up, you can start using it immediately. Luke, you know, one of the things that we heard during, I loved the customer, the keynote this morning, customer examples, Rebecca and I and Dave were talking about that this morning, and it was a really dramatic, bold story told consistently through the voices of customers this morning on stage. I don't, we don't see that to that, I haven't, to that level of like dramatization, but I thought it was really impactful. But one of the things that I wrote down that I loved that Rob said is anything that AI can do, AI and automation can do better.  Obviously it varies, it depends. The answer is D, y'all will be above. But give us, Luke, some perspective on AI and automation better together from UiPath's perspective and how that's going to impact your customers. Yeah, Lisa, so, you know, I think, actually Mary said it well this morning around, you know, if you think of AI as sort of like the, the brain and the automation as the muscle, these two things together really make AI, put AI to work in the enterprise.  And of course you heard Graham talk about earlier today specialized AI and generative AI. But with generative AI, it's sort of the use cases that you see today really have generative AI locked in this personal productivity type of use cases where it's helping you, it can do, you know, it can do things like write texts, it can summarize texts for you really well, it can analyze data, but it's sort of relegated to these personal productivity improvements. And what really with UiPath, what we're focused on is going beyond just personal productivity and actually making it productive for the enterprises. And you know, I think that's, when you look at the capabilities that we bring to the table to help do that, first, you know, what is it, so what does AI need to actually, you know, make it work in the enterprise? First is context. So you have to bring context to the AI in terms of information so they can make the right decisions. You know, how valuable, we heard from Walter Isaacson earlier on the keynote stage as well, and he's an amazing author, I love Walter Isaacson, but how many people would actually hire him and put him day one answering customer inquiries and writing back like responses to customers? Well, you probably wouldn't because he doesn't have the context, he knows a ton of information but he doesn't have the context to know, you know, how do I respond to this customer to this type of request? Where do I get the information? Where do I enter information to be able to do what they're asking me to do? So in the UiPath, this context comes from our integration service and bringing that data in. And then the other elements are really around action. So being able to give AI the capability to take action is really what UiPath is all about. So it has to go beyond, to put AI at work and make it productive in the enterprise, we have to do more than just allow it to make decisions with that context, you actually have to allow it to orchestrate the movement of information from system to system and enter it into, you know, do an invoice processing use case, enter that data into a system. So that's really what UiPath is focused on and, you know, context and providing context, enabling it to take action, that's where we amplify AI with automation. I want Walter Isaacson as my customer service rep. No! I think he might be a little pricing.  What's progressed on the integration fronts? What are customers benefiting from one year later? Yeah, so we've been super thrilled to have re-infer as part of UiPath and in April we announced the true integration of that into our platform as communications mining. So communications mining has unlocked a ton of new use cases for the platform. So around unstructured communications from customers, then being able to look at what are the communications that our customers are emailing us about, for example, being able to understand that voice of the customer, but then actually going beyond understanding the voice of the customer, but actually being able to automate what based on those inquiries of, you know, can I cancel a policy? Can I upgrade my policy? Can I modify my insurance policy? Things like that. We can now automate those things inside UiPath platform. Whereas before, you know, re-infer could route emails to different people based on who was emailing in about what topic, but now we can actually take action and actually orchestrate the movement of the data and the automations downstream. And so this combination with our orchestration and automation, but also our document understanding product has allowed us to expand our intelligent document processing suite to beyond just documents, typical documents you would think about to also customer communications. So when that customer communication comes in and has an attachment, we can now act on that attachment beyond just like what's the content in the email. And so, you know, it was reflected, I think, well in the Everest report that came out earlier this year around intelligent document processing, which ranked UiPath as the clear leader in that space. But one other, you know, one other aspect to the integration of the communications mining into the UiPath platform, this goes back to something Alan was just talking about, which is how do we make applied AI for more than just like the data scientists in an organization? And really we've taken the active learning capability in communications mining, which allows a non data scientist to create machine learning models without knowing any of the science behind it and rapidly train these models to understand the specifics of their domain. And we've taken that, and you heard an announcement earlier today from Graham that we've introduced active learning and document understanding inside of UiPath platform as well. So not only have we taken the technology and integrated it very deeply, but we've also take the learnings of how we can take these non data scientists to train AI models and infuse that in other products inside of our suite. So we've benefited in multiple ways and we're seeing great adoption of the communications mining capabilities in our platform. Awesome. Alan, I'd like to ask you what your take is, what your perspective on UiPath's progress with IDP and communications mining and how they should be thinking about making sure that these IDP systems are fair and transparent and sort of what are the other considerations to take into account? There's lots of considerations to take into account. I think the one thing you could take a step back, so intelligent document processing, it's relatively new. Document processing is really old, it's 30, 40 years old. Just wasn't very good before. Again, the last few years advances with AI have meant that the accuracy level, say, for reading the text on a document in very simple terms, way more accurate than a human, right? So that's a big threshold to get through. So that opens up a whole world and the initial targets are basic, basic, basic business documents, invoices, bills of lading, statements, whatever, the basic currency. But what things like re-infer do is they open up the possibilities more, right? So you have IDP for what we would call long-form documents, like very long contracts or whatever, that's cool. But most communications are not big, chunking formal contracts and leases, they're email messages, they're text messages, they're, hey, Bob, did you see that? Shall we do something about it today, tomorrow, whatever? And so that starts to open up those possibilities and I don't think we've even really started to explore what those possibilities are yet. That's how early we are in the market, that's exciting. So how are you tracking the progress of these initiatives and what metrics are you using and how are you determining? Really hard, that one. Because it's such a, it's a very English phrase, but fighting with fog. Every time you try and do something, it's changed and it's moved, right? So there's those kind of things. I think there are metrics, I mean, there are metrics in the sort of formal world around bias and whatever and there's a whole world, sort of sub-world, if you like, evolving around AI ethics and benchmarking and maturity and accuracy and everything. But outside of that, when, you know, I use the term enterprise, but it could be a hospital, it could be a government department, but large organizations, right? When they're deciding whether they're going to use AI, well that means they're going to have to invest, right? Because it's change and change costs money. I think that's where there's a lot of shift going on at the moment because unfortunately we see things like AI and RPA in the past and the current probably as, oh, they do the job of a human. So we need less people. That's not a good business metric. No. It's not very nice for one thing, right? But it's actually not very accurate. The reality is, you start these projects, oh, we're going to reduce headcount. No, no, no. They're probably still going to be there at the end of the project. You just spent some money, you've still got the same people. It's not a good metric. Improving accuracy, reducing errors, improving customer experience. You know, I won't say the name of the hotel, but I was trying to check something at reception this morning on the phone, right? Press one for this, press error for the, oh my heavens, right? Those kind of experiences. You've all been there. We're there every day, right? Yeah. Those are the kind of experiences when something isn't paid on time, when your appointment's been canceled, when your insurance claim is in limbo somewhere, right? These are the kind of things where you take correspondence, so re-inferred, you take correspondence, you take messages, you take those documents. And I'm not saying we're quite there today, but you can get to that point where you can get an answer to a question. You can get a response. And as a human being, alleluia, right?  But that's awesome for the organization too. Because errors, angry clients, angry citizens, delays, inaccuracies, that's not fun for anyone. That's expensive, yeah, but it's also just pain. Right. But you're trying to get rid of it. Yeah, yeah. Luke, what, I'm curious. This is a question I always grapple with because there's so much negativity in the news about AI. And I think, you know, I feel like those of us that are in technology have some sort of sense of obligation to help on the awareness front to really start lauding all of the positives that are happening from it. How do you, in customer conversations, what are some of the things that you talk to them about in terms of, you know, not to Alan's point, not reducing headcount, not eliminating jobs, but really enhancing, empowering. Where are customers with that good, bad, neutral kind of perspective? Yeah, I think this also ties into sort of Rebecca's question around the, how do you track the success of these sort of endeavors? And you're right. So we look at this as freeing up people's time to do more creative work, right? If I'm constantly replying to the same email that's coming in to my help desk, that's a very boring task, right? We want to take away that drudgery and free up. Unless it's Walter Isaacson. Unless it's Walter Isaacson. Yeah, yes, of course. I would love to get an email from him. But, you know, I think on one side of the coin there's, how do we free up people's time to do more creative work at work, right? And there's different ways to measure that. And that is, I really like to add, like, you know, it sounds a little boring, but average handling time of an employee, right? So if you're reducing the, so when we have these AI processes, we bring humans in the loop to actually validate what the AI is doing oftentimes, especially the more important or critical process, the more you want the humans to do validation. So you're not always reducing the work to zero. You're actually just allowing them to do more, but actually, you know, with less of the drudgery, they're just checking what the AI output, right? And so in that way, they're still handling the email, but their average handling time of those tasks goes way down. So that's one side of the coin. We can measure that in a bunch of different ways, but I've seen average handling time of a process be very, you know, of the human interaction in that be one way to measure how much time you are able to free up that creativity. The other side is customer satisfaction. So if you're able to actually, you know, process a customer request and get something done that they asked for it faster than you were before, where they might have been waiting days for somebody to do something that is working through a backlog of emails, you're going to get better net promoter score up from your customers, right? You're going to get the customer saying, yeah, I love working with them. I love the type of customer support I get from that company. So that's really the other side of the coin beyond just, you know, freeing up people's time to be able to do more creative type of work. So yeah, that's really like how we see that the ROI on those two different angles of it. Yeah. Last question for both of you. What are your thoughts on the next evolution of IDP and Com's mining? The next evolution. So I think there's lots of different angles you can take on this. Like more specific to IDP, the AI is getting better and better and better. I think we're going to reach a point, probably not in the two-distant future, where every document, intelligent document processing platform, it's sort of like the AI itself somewhat gets commoditized because it's reached thresholds of how accurate it can be, right? It becomes a point where there's diminishing returns on actually what the AI itself can do. And it becomes more about all the tooling and capability that surrounds the AI. Like being able to bring a human in the loop to validate what the AI's output is, being able to monitor those success metrics of how well the process is performing in your automation.  What's the customer satisfaction? So and we think UiPath is really well positioned there because we're not just an IDP vendor. We provide this capability around it that allows you to measure the success of the process you're automating and be able to do things. We're working on things like to allow you to simulate how your process is going to do before you even deploy it. So that tooling around it, human in the loop, simulation, being able to monitor and audit what's happening in your automation, those are the things that are really going to make the difference in the end because the AI itself will reach a point of diminishing returns and what it's able to do. Alan, final word? I'll just take it from a different angle. I think, you know, at the moment, the traditional world of document processing has been about things like accounts receivable, accounts payable, really, really boring stuff, but very important stuff. I think now it's becoming democratized. I mean, I was a different thing last week and there was somebody talking about a real case study in South Carolina, I believe it was, where it was to do with foster children. And they moved from an 18-year-old access database and handwritten paper and forms to an electronic system. When you go out there, and as an analyst, I try very much to do that, keep one foot in the sort of, if you like, the Silicon Valley world, another foot in the real world, you go into supply chain, you see the most amazing technology on cargo ships, then you go into the office and explore to ceiling with paperwork, right? So that's what I'm excited about is there's a whole world of paper out there. We live, when we're in the tech world, we live in a world where we seem to think everything happens digitally these days. That's not the case. It's just not like that out there. And the opportunities are almost endless. And again, that brings benefits to everybody if we can get that right. So that's great. Great note to end on. Alan and Luke, thank you so much for coming on theCUBE, a good conversation. I'm Rebecca Knight for Lisa Martin. Stay tuned for more of theCUBE's live coverage of Forward Six. We'll be right back.


This summer, we have a very exciting internship coming up for the teens and young adults. For anybody that wants to join, you're all welcome. If you're local or if you're not local all around the USA, you're all welcome. One of the things that our church focuses on is the power of evangelism. Learning how to evangelize, to pray for the sick, how to lead the lost to God and deliver the oppressed. And during the internship, we will be learning how to do that as well. You will have the opportunity to go into the city and pray for everybody that may need prayer. And not only will you be learning how to do this, you will be able to also implement this by going outside of the USA and serving to those outside of the country. This summer, at the end of the program, we will be taking a trip to Mexico with the interns where you will be able to implement all of the things that you learned. You'll be able to pray for the sick, be able to heal and lead those who are lost to the Lord. Also, we'll be visiting orphanages, playing with the children, visiting rehabs and bringing any kind of care that those locally will need help over there. We would love to have you with us. Please sign up.


and what's the latest with Nordic? Well, the latest I think is that we have more solutions and more devices than we ever had before. This year, since last CES, we've launched new devices and everything to attend. We have multiple software solutions. Now we can offer Bluetooth 5.0, Bluetooth Mesh, Tread, multi-protocol solutions with those protocols. What is this stuff? What is it? LTE, M, NBIOT, are you big in that? Well, we are gonna announce our initiatives in the seller IoT space. We do have development going on for LTE, M and Arabian IoT. On the 22nd of June, we're announcing our products in that space, which we've been working on for the last three years. So we expect that the next big thing for us after Bluetooth will be seller IoT based on CADM and Arabian IoT. And you'll be providing low-cost, low-power solutions? For that low-cost, low-power, developer-friendly solutions for that, yes. And so is this what it looks like when your stuff comes out in these wafers and all the Nordic semiconductors just in a bunch of wafers? I mean, we do thousands of wafers every year. And typically there are anything from a few thousand to 10,000 devices per wafer. Then they get cut up into pieces and put in plastic capsules and bonded out. But it all starts on the wafer side of things. And one of these, how many percent is good? How many is usable? You know, that's typically a trade secret, right? But we should be on the 90s. 90s, so that's how you can get low-cost? That's how you make sure that, first of all, you've got to have a manufacturing capability. You need to have your manufacturing process on the control to ensure that. But of course, yeah, the better yield, the more better price you can do on the devices. And are there tens of thousands of different products using all these, what is this penguin there? All kinds of, maybe it's not a penguin, but all the, like if anybody's doing IoT wearables, they're all thinking Nordic. I think a lot of customers do. Now we track design ways worldwide and we think we're doing like 40 to 50% of all things happening in Bluetooth, low energy. And I mean, it comes from all kinds of devices. There's not a particular segment necessary that we dominate. It is the innovation of our customers that comes up with ideas and crazy products that no one thought about. And some of these turns into big volumes. But I think our focus has been to do developer-friendly solutions, easy to work with, easy to start, get the prototype quickly and make great products. And Beacons, you're the leader in Beacons. A lot of customers are using devices from Beacons. I think they like our support we've had for years. We've always been early supporting IE Beacons at Google versions, physical Vab. We had upgrade ability. So a lot of customers have been with us for a long time on Beacons. And all kinds of partners from many different places making tiny little modules and some Swiss modules over here. As you're seeing our list of a number of our module partners, not all of them, but modules become more important for us from a smart home and industrial point of view and more customers are doing modules. And I think we have during the last years, make sure we build relationship with the most reputable manufacturers of modules. And what else are you showing at the booth? Do you have some new security solutions? I mean, hardware security or? Our latest ship, the 52840 is using the ARM CryptoCellT-310, which is, I think it's a gold standard in terms of security, implementing hardware, a whole range of encryption schemes. So that's included in the 52840, our latest device here. Is that the Cortex-M-0-1? That's the Cortex-M-4F. Yeah, this device has a one megabyte of flash, 256K RAM. You know, it's the best, most powerful radio we ever built. It's the most secure device we ever built. It's our flagship device, which we're moving into production now in February. And it's been in design with customers for the last years. We have a lot of expectations for this device. And when the ARM V8M comes out, you'll be at the forefront of that, probably. I'm just guessing. Well, you know, we're always looking at new technology from ARM and all our partners. And we try to leverage what's new. You know, until we announce things that cannot really say, well, we're going to put in. But again, we look to have leading edge products. You're busy, right? In no way. In no way. Yes. And all your designers, your chip designers, are always busy with the next thing? Of course. I mean, we've announced things now. And we have showed devices that's coming now, which comes later this year. And of course, we're working on devices that's going to come in 2021 and so forth as well. So there's multiple projects working in different time stages for various products. Everybody at CES, everybody at all the, I don't know, big gates. Everybody's talking about IoT. They're talking about wearables. And you're basically in the middle of it. So you must feel proud, no? You're like, it's very good at that. I always like to say that. We used to do IoT for a long time, or we used to do a lot of internet of my things.  But you know, some of the IoT is not that new in a way. I mean, it's been around for a long time, but as these businesses now becoming bigger and bigger, I think we are in a very good position of capitalizing on it. How long time have you been doing IoT? I think we've been doing IoT for the last 15 years in some way or another, right? So you've been doing, before people call it, IoT? I think so, because it's about bringing some data from a sensor to somewhere it processes it in the cloud, acting on information, controlling things. It's just the simple things in my view that of course you made more complex. So the owner of ARM, he was on stage last year and he said, I want to ship a trillion ARM processors every year. Are you going to help him? Yeah, of course. Do you have plans to do trillion... Are you going to print them out, like plastic-based chips? What are you going to do? Is it going to be on the floor and the walls? What's next? I think we're going to look more similar to what it is today, to be honest with you. And I know that they have big ambitions around. We are contributing pretty significantly to that volume every year, but it's of course a long way to go for a trillion devices per year. How many are you contributing every year? Is it secret? I think we're not announcing that number, yes. It's probably in hundreds of millions, right? We do a portfolio product, some with ARM, some without, and we typically do around 300 million devices per year, but there's a mix of older things. Most of the ARM stuff you're selling? I wouldn't say that. Maybe not. There's some other stuff, too. There's older stuff that before the ARM era I've noted. All right. So there's a busy booth here. Actually, right here, it seems that all the booths around here, like more than a half of them are using Nordic, right? I think everyone's using Bluetooth as well. Of course, there's a lot of our customers around here. I think Bluetooth is really the big star of this show as well. You know, seeing the marketing themselves, there's a lot of things going on, and Bluetooth has really come a long way of becoming a dominant standard in some way. All around us, of course, people are using Bluetooth and all kinds of things with our devices, or sometimes our competitors' devices. I think Bluetooth, of course, is great, but is it becoming better and easier to use? Are you helping them to... You're part of the Bluetooth consortium, and is one of the priorities to make things to pair more easily, more seamlessly? The question of pairing has always been a tough question in the Bluetooth sync, to be honest. There's always been the question about who's responsible for a solid pairing or not. I think we've come a long way with Bluetooth in terms of functionality and making it better. Something we've done on our devices is actually to support NFC as well for pairing, which is, to some extent, making the pairing experience even better and easier to do. I wish I could say that it will be very easy, but it still is a little bit tricky to get the pairing going. This applies to all wireless standards in some way.


Welcome to English at the Movies, where we teach you American English heard at the movies. Today we are taking a phrase from the movie Vacation. It is a comedy about a family taking a vacation, like the one the dad took with his family 30 years ago. The phrase we want you to learn is, stand on its own. Let's take a look. My trip to Wally World when I was a kid was the best time I ever had. So you want to redo your vacation from 30 years ago? We're not redoing anything. This will be completely different. I've never even heard of the original vacation. Doesn't matter. The new vacation will stand on its own, okay? So what does that mean to stand on its own? Stay in one place or be independent of others? Let's listen again and see if you are correct. My trip to Wally World when I was a kid was the best time I ever had. So you want to redo your vacation from 30 years ago? We're not redoing anything. This will be completely different. I've never even heard of the original vacation. Doesn't matter. The new vacation will stand on its own, okay? To stand on its own means to be independent. The family is going on vacation. Even though the dad made the same trip when he was a child, this vacation will be different. It will have its own identity and memories and stand on its own. And that is English at the Movies. I'm Anne Ball. I think this is the beginning of a beautiful friendship.


In this room you'll notice two hats. Above the far hat is a coin. If you select the coin you can move it around in space. With the scroll wheel on the mouse or by bringing your VR controllers closer to your body you can bring them closer in space. See if you can drop a coin in the hat. By allowing your users to bring objects closer to themselves without having to walk in physical space you open your app up to people with disabilities and those who don't have big rooms.


Prime Minister of St. Lucia and member for Castries East, executive members of the Marsha Football League, staff of the office of the Prime Minister, good morning and welcome to this handover ceremony for the Marsha Football League, who will be participating in the semi-professional league in St. Lucia beginning Sunday 10th March. Admittedly, I don't know if there's some sort of, bias hair, but our first march will be on Sunday at 2 p.m. at the Mindo Phillip Park between Marsha and Babano. I would now like to call on the first chair, Mr. Marlon Desi, to offer some remarks on behalf of the Marsha Football League. Good morning, Honourable Prime Minister, members of the Marsha Executive and Technical Committee Marsha Football League. On behalf of the players and extension of the community, I'd like to extend my gratitude and appreciation, the Prime Minister, for assisting us with this, with the boots and the uniform for the upcoming professional league. It will go a long way in ensuring that our team progress in the competition and hopefully next year we'll be in the top tier where we'll try to achieve greater things. And so on behalf of the team, the Technical Committee, the players and Adlergy community, so I'd like to thank you for your generous donation towards the team and the community at large. Thank you. Thank you, Mr. Desi. And I know that the semi-professional football league is one of Prime Minister's babies, amongst others, the UC economy being another. And knowing that Marsha and Cassie's has produced many footballers, I remember my younger girl days of it, growing up in Marsha. I'm going to see many football games. So I really hope that this league inspires many more young people to take opportunities for not just recreation, but for football, for sports, as a business, as a career. I would now like to call on Prime Minister Honourable Philip J. Pierre, Representative for Cassie's East to give some remarks. Prime Minister. Thank you very much, Monday. Good morning, everyone. Morning, members of the Marsha Football League. First of all, let me say to all the women of Senusha, Happy International Women's Day, I hope I have the right colours, so my pupil is correct. What's happened this morning is symbolic. Not in terms of the contribution or the donation or what we are giving the Marsha Football League, but in terms of a philosophical advancement as to where sports should be in this country. The semi-professional league is the first of its kind in Senusha. And what it seeks to do is it seeks to create a livelihood for footballers in the first instance. What do I mean? I mean that footballers at some point are going to get paid for paying football. This is revolutionary. It's the first time in the history of Senusha that that is happening. It is a signal that the government and hopefully the sponsors have confidence in the young people of Senusha, have confidence in the discipline of the young people of Senusha. What can that do? We can create a whole industry in sports. Sports is an industry and there will be cynics that will tell you it will not work. There will be cynics that will tell you it's politics. There are cynics that will tell you many things. But the question is, just think of a community like Cassius East. Think of a community, just think of it. Let's just imagine and dream. Because life starts with a dream when Julian Alfred was going to school and he was being coached by Twatine. She never knew she might have been where she used to be and we never know she may be Senusha's first gold medalist in the Olympics. So let's dream. And we mustn't allow cynics and critics and envious people to spoil our dreams. We have to dream. Let's dream about semi-professional football. Let's just dream about it. We start. We start small. We have two tears. Marsha is in the second tier. She'll get to the first tier. Then they start playing for some money. Just think about a scout or scouts from somewhere in the world. Picking up one player, this one. And I'm sure there's a talent for that in Senusha generally. Picking up one player and taking this player, taking that guy through and he gets to play Premier League football in the UK, in England. Think about it. Just think about it. Just think about two or three players. Football is an international sport. We have the talent here. Think about the industry that can be developed through football. Think about the coaches. Think about the psychologists. Think about the people who deal in the massages. Just think about the industry that can drive. Think about the people who are going to sell in sports equipment. I want to congratulate Ari here for his contribution, his involvement. And one as a government, the government has removed that on sporting equipment to create, to encourage further. Hopefully we're going to reduce the price of football equipment or sports equipment to be reduced by removal of that. Just let's think. Let's think about the glass being half full instead of being half empty. I can tell you that can be the beginning of greatest things to come for Senusha and by extension for Marsha, for the communities and by extension for Senusha. So what you're doing here is basically symbolic. It's not because we believe that we want to get publicity, but you want to reach out to the young people in Cassie's East and the young people in Senusha generally. Let us talk this attitude about you from the ghetto and your mentality must be ghetto-ish. The ghetto is in your mind. That's where the ghetto is, in your mind. Life was never easy. It would be tougher for some people. The government's job is trying to make it easier for most people and for all people if they can. Think about the football stars who were brought up in slums of Brazil and Mexico. Think about them. I can't mention them. They all never can mention the names I want. Those who are brought up in the slums of Africa was of, and I can say it without any fear or favor, was of any place in Senusha, was of. Look at where they are today. If they had sought about the ghetto and the system and them fellows and been encouraged by envious people, people were selfish to have that mentality. I don't want to mention their names. Look at where they are today. World stars, global stars. They started in a little town in Africa, in Brazil, in Mexico, in Ecuador, in that's where they came from. And look at them today. So I want the sportsmen and women in Cassus East and in Senusha January to think like that. Not everyone is going to achieve it. Everyone can't achieve it. But some of you can. And I'm very happy with these gentlemen here who are taking the time off to work and mentor with these people, these young men. Them theirs is a labor of love. Because it's not easy because you're fighting many, you're fighting many battles. You're fighting many battles. You're fighting battles with gang leaders.  You're fighting the people who are political. You're fighting of all kinds of things. You're fighting the selfish people. But what you need to do is I need you to focus. As a parliament ship and as a prime minister in Senusha, my position has been clear. Politics and sports do not mix. And I have never, I will never use politics for my political grandestment. And I've represented that constituency since 1997. I've represented that constituency. And no one can testify to me ever asking them to do things for me to get votes. I get my votes otherwise. So I just want to encourage you. I want to encourage you to march and football. I want to tell you, let's keep our eye on the price. Let's forget the division and diversions. This is just to put us off. The divisions and the diversions and the fighting for toughness is to be focused. Our focus is for the whole, not for the individual. There is absolutely no perfect human being. Don't look for perfection. There's no perfect human being. You can't find a perfect human anywhere in the world. Why are we looking for perfection? Just be focused. I want to congratulate you. I want to tell you that today we are assisting. But anything that I can do within my capabilities, because the prime minister doesn't own the treasury, within my capabilities, I will do. The government has started. We've removed the vats. We've funded the semi-professionally. We are going to be preparing, I want to tell you today, that we are going to be repairing the Martian grounds. We are going to be repairing the Martian grounds. That should finish by the end of this year. But I'm warning. I am warning. Vandalism will not be tolerated. We spent about a million dollars on the Martian grounds already. You cannot see it if you look for it. The fence was damaged. The toilet facilities were vandalized. A million dollars we spent already on the Martian grounds. This time we're going to probably spend a little more than that because you're going to be redoing the stands. But I'm putting the people, and not the players, the selfish people who vandalize that the police will be asked to take whatever measures they can take to stop this vandalism. We cannot tolerate vandalism when government spends taxpayers' resources to be repaired. They do me nothing. When you destroy government facilities, you don't learn to me. I pay my taxes like anybody else. It's not me. It's not about me. Damaging the sports infrastructure in this country. When you mash up the fence and you mash up the roof and things, you do me nothing. I don't play any football and sports again. It's not me. You don't do me anything. What you do is you selfish and you cause, first of all, your community to have a bad name. And secondly, you deprive people of using these facilities. And then as we go to look for sponsorship, I want to implore and beg the players to be disciplined, to behave like people who appreciate sponsorship. Not from politicians, but from the people who are assisting. Show some level of discipline and understanding. So thank you very much and thank you very much for the martial football league. You guys are unsung heroes that make a sacrifice. I know it can be easy. I've been around for a long time. I know what you go through. I know to get these guys together in any shape, form, or manner. And to tell them that this and that. And it cannot be easy. And you're not getting compensated. But do it for the value of your country and your body. So I want to thank you. I want to be sure the best. On Sunday, I will not be there to watch the first match for the lunch. In fact, I was expecting to speak at the lunch, so I gave my speech here. So I want to also tell you that the Minister of Sports is very, very, very excited about it. More has happened to sports for Saint Lucia in the last two or three years than happened for a long time. There's going to be a process of going to be repairing playing fields. We've done a playing field in Miku. Hopefully, as soon as St. Jude is constructed, we're going to be competing in the National Stadium in Feoffort. I'm going to repair it. We're doing work in the Mindefield Park. I told you about working on the Marshall grounds. We're doing work on the Darren Sammy grounds. We're doing work on Rosalie playing field. So we're going to be constantly improving the facilities in this country. Saint Lucia has been doing pretty well in sports. We're going to be building the National Aquatic Center. That's construction will start soon. So our sports game is doing well. So thank you very much, and I wish you all the best. Thanks. Thank you.


Good afternoon, so I'm going to talk about something that's dear to my heart writing beautiful code So before I start let me introduce myself So my name is Anand. I Teach Python professionally I conduct advanced programming courses at People Academy. I'm also a Co-founder of a startup called Roto data. We're building data science platform there So I use Python heavily at my work and also teach whatever I'll lend to students So let me start with the code from Christopher Alexander who coined the term the bad and language So it's really hard to say What is beautiful? Have you ever looked at the code and actually felt wow? This really looks awesome. Okay? I would felt raise your hands Yeah So And it's really hard to say when a code is what a code if you do what makes your code beautiful Okay, so it's kind of some people say it's Alexander Christopher Alexander says it's the quality without a name So you look at it. You kind of feel it but it's very hard to say so he talks in the context of Architecture but applies to many other art forms as well if you consider programming is also not So let me quote This from The way it's called a wizard book structure interpretation of computer programs This is the programs must be written for people to read and only instantly for machines to execute. It's a profound statement because Usually people we think programs are written to just get some job done. Okay, so we write for computer to execute something But if you look at it deeply programs must be for written for people the reason is If you look at the life cycle of any typical computer program Write once first time for the computer for the for the remand duration of the lifetime of the program Sometime I mean someone else look at the program up at some time. He has to understand the code or a lot of times What happens is we write a code and after a week or two We just can make sense of the program. I'm sure like all of us went through that face Okay, so it's very important to write programs to keep in mind of The people are going to read the code later point. So we should always try to improve the readability of the programs so Let me start with the very simple low-hanging fruit that everyone knows that I had to do it But not many people do this. Okay, choosing meaningful variable names. It's so important that Even people with a lot of experience fail to pay attention to this I teach Python professionally. I do Python advanced Python courses to Working professionals So I really find it frustrating when people with like three four years of program experience and I can't even pick right variable name It's not that they can't pick but just that we don't just pay the attention to those details I'm going to show you with couple of examples. How important it is to pick a variable right variable name So let me quote Phil Kaltran on that two hard things coupled signs are cash in validation and naming things Believe me naming things is not easy. It's hard What's the longest time you've spent? Banging you had to figure out what name to give to a class or a file name or a variable. I Remember having spending Literally two full days to figure out. What should I name this thing what I'm trying to implement. Okay, so Naming things takes time and we should give the time. Okay It's very very important to give that So the first tip is I want generic names that really don't make sense if you want to So what we do is you want to have temporary variable temp temp to manage your data It's kind of it's two generic names. You really can't understand what they mean had to use a little more specific names for example Yeah, so you choose a little more specific names to the context what that means The other thing is So the red is to indicate not so nice code and the green is one which is What's what I'm suggesting? So avoid using abbreviations People say UCF uppercase Formatter, but doesn't it's people can't understand what UCF is. It's okay if it's saying it's ETP or SMTP because that's a Well understood acronym. So that's fine But using something like BA for a bank account doesn't make sense. Okay, it's very hard to understand You can probably say formatter or an account or something. So That's a I think a good thumb rule. Don't use abbreviations unless that's very common. I think that Everyone knows This is another common mistakes that I keep finding in people as These data type has a name of the variable. They say it's a list It's a string. Okay, but list of what? String holding what right? So it's better to say Actually, what it says it says some of numbers Count words it takes a string, but actually a sentence. It's not a paragraph. It's not a file name. So It's better to say specifically what it actually Means not just saying the type of it. So that makes it a lot more readable the other a thumb rule about nouns and verbs is Use nouns for variables and classes Saying concepts and use webs for functions So saying actions. So these are the tasks that you want to do. So size price task scheduler, etc They go well for variables and classes and use actions get file name instead of just saying a function as file name So get file name so that it kind of indicates you're doing an action or mic account or a deposit So these are the kind of examples where Using webs makes sense for functions and Okay, they're not It's very simple rules not something that I've invented These are the age old wisdom that's been talked about from so many people if you Find out practice of programming or there's so many other books people have written But I'm just trying to take that wisdom and Put in the context of python so if you look at If you have a list of values, it's good to Use a plural for that So say a largest line Of lines or always start listed directly and you get files there, but Look at other Examples a file equal to always start listed directly. It's not a file. It's a list of files So better to use a plural to Say that it's actually a list of values and this these are examples actually Real world examples have Found from people when I'm doing teaching. Okay, so people say for lines in open filium dot read lines Reading read lines gives you a list of lines But each element is a single line not lines. So And saying into off lines doesn't make sense at all right, so It's better to use plural for a list and When you use loop indices These are y and j for loop Indexes only not for the values. Okay for example For i in range 10 is fine i is an index you're going over its values 0 to 10 But if you're going over a list of values using i it doesn't make sense because i is usually used for an index and If you're using i for numbers that feels like It's a single integer, but n could be a number or it could be a string or anything, right? So use something which is more Canvas what actually holds for any numbers probably more makes a lot more sense you might be thinking like Why am I talking about silly things like these are things what everyone knows, but it's really really hard to get this in practice Okay, let me show you an example This is a small filen function I've written. Okay Can you try and understand what this is doing? Can someone let's take a minute and then see what this does can someone explain me what this function does Wow awesome. Yeah, it's actually that's what it does. Okay, but let's look at this. Okay, so If you look at the same function I've written like that Okay, all I've done is I've changed the Names I'm not changed any structure of the program. So, uh, it's just a filen program And it's really hard to understand what is doing x and y and they're adding things to z. Okay So by changing the names it made so much of a difference. Okay Now by looking at immediately, you know that it's the data set It's an index and you're taking a row and then from the row you're taking Yes, I know I know but the thing is I'm talking about uh I agree so I picked this example because uh To show how much difference names makes I agree you can use this comprehension, but just uh trying to show how much names makes sense, okay, so If a filen code can make so much of a difference In picking the right variable names imagine what would happen if if you're working with the final line program or 10,000 line program, right so Uh, it's really really important to pick the right names so the other uh Thing is when you're using similar names For completely different data types. It's kind of very confusing. So when you're writing code, uh, you should also keep in mind what people think Unconsciously, okay, so when you see uh names which are sounding similar We unconsciously expect that they actually hold similar type of values. Say a1 and a2 You think they must be the same kind of values, but if you put a list in one other integer, that's very very confusing. It's very hard to uh, Make sense of that So probably say values are an instance of saying a1 and a2 And that's that's one of the issues that we had in the previous uh example as well We say x and y kind of feels like x and y must be the same types We may both are lists or both are integers or something, but they're not, okay Now let's uh Look at comments We all say people we all say writing comments is good, but uh, is it really when there's really no need to say the obvious, okay uh increment x by 2 That's okay. I mean python programmers We look at the python code and figure out the incrementing x by 2, but that's just that's the obvious thing There's no right need to write a comment But you can actually explain why you're doing it Compensate for border on both sides or you're adding one pixel on both sides So you're adding two so that makes more sense you're conveying why you're doing that So don't say the obvious say why you're doing that And a lot of times it makes a lot of sense when you're commenting, uh Add a comment to explain why you made the choice So the following is an optimization saves a lot of memcache cals So I'm saying that this is the reason why the following code is being done this way And also it's a good to document special cases for example, uh, You figured out there's an unicode error happening and you don't know why what's happening and this magically Fixes that issue. Okay, so Put a timestamp and say this is a special case. Uh, and this is how I'm fixing it So in future people will be careful when attaching that part of code and it's actually, uh Good if you can actually make comments redundant, okay Can write code such a way that you don't really need to write comments For example, if you look at the first case, uh, the fine length of the longest line So there's a list comprehension and finding the max of that. Okay Instead of that, if you say any code length of longest lines You don't really have to comment that it's kind of it's very clear in the program itself So you can write self-documented code. So, uh, the code is simple enough for people to understand by the Code itself, you don't have to write the documentation. So that's something Really awesome if you could do that Uh, yeah, the other thing is if you have longer functions What we typically do is you have stage one stage two add a block comment say that this is what So process documents and upload them to search engine and there's a part of code, but uh, it makes More sense to split that in two smaller functions and then say docs equal to process documents and then Submit to search engine. So you don't really need comments to explain that part of code now that we have looked at Uh, the simple things are more accessible things like variable names and comments. Let's look at Program organization. So how do you structure your program? So divide and conquer so split your program into smaller independent modules and functions That way it's a lot easier for people to make sense of that Let me code Miller's law what it says is Number of objects average human can hold in working memory seven plus or minus two It's a profound it has profound implications on uh how We should write our code reason is Seven plus or minus two is the number of things that you can hold in your head. That means That's probably means when you're writing a function You should not have more lines on that Or you have a class then a number of methods that in your public api should not be more than that So when someone looks at your class and then, uh, starts working on it starts using it If it has seven plus or two minus functions Then you're able to kind of keep all of it in his working memory and then able to work with it But if it has a lot of them, it's pretty difficult. So that's a kind of ballpark figure to keep in mind when you're writing, uh Classes or functions. So I think that's a good number to keep the size of a function as well and the Other common thing people always Don't pay attention as uh is duplication. So duplication is bad. Uh So for example, uh, it's a function. It takes an input data and tries to Uh, convert that to an integer and then sums them up and give the value back. Okay so Uh, since I'd say uh data is coming from users. We want to do some, uh Violation and converting integer before we actually do the summing up. So there's an uh try and accept But we're doing it twice if he's actually a deliberately added and So just people we write one thing and then copy paste and then modify things and Uh, you see I kind of uh deliberately left x here because that's uh, that's kind of errors that we usually get into. Okay, so Instead of duplicating we should it's a lot better if you can actually generalize that say, uh, uh, you get into Take input data and then uh x and y and uh, We're in x and y. So if you look at the add function here, it's very easy to understand now than what we had before Now, uh We should also avoid uh too many nested levels when you have a function. Uh, it may have May end up like writing code like this. Uh, uh, it's updating a blog post So there are many cases where you want to update a blog post You want to update a title or a tag So there's a big function that kind of uh going over the steps But if you see that too many levels of uh, Too many nested levels here. So that's kind of hard to understand So what can be done is uh, you can uh take each part of that and then make that separate function that really makes It a lot more readable. Okay. So if you look at this function, this function is just delegating it to uh, other sub functions So if you look at this function, it's easy to understand and if you want to the further details You can look at each of this, uh other functions The uh other uh useful thing is to make sure you handle errors separately. For example, this function is trying to uh get Uh user from given the email address So you first check if it's a valid user or not If it's a valid user, just make sure that the account is not blocked And then you query the database and give the user back But if you see the code of the function The main function of uh of this uh, this function is hidden in two levels deep Okay, so the query so that the level spreading is the is the core of the function, but that's Hidden deep inside uh So many conditions, okay So wouldn't it be wouldn't it be better that to be the most prominent part of the function? So what I can do is you can keep the errors handling uh separate For example like this. So we have you do the error validation first and then Uh in the top level you have uh the code of the functionality So you get a query and then uh query the database get the results and if you really trying to understand this function You could just skip the error validation and then directly jump to uh the main part of the function, which is Uh not so straightforward if you're uh doing it like this Now the other uh Very important thing is uh, we should try to suppress implementation detail as much as possible The reason is when someone is trying to understand program Uh the intent the what of what the program is doing and how the program is are doing are two different things So whenever someone comes to your program is is more interested to understand what the program is doing, right? So uh, we should improve it. We should suppress implementation details as much as possible so that you can understand, uh Uh The intent of the program pretty quickly quickly and then if required you can go and then see what uh each of those functions are doing For example, this program takes one common argument Which is a file name and then reads all the words in the file Computes the frequency of the words and prints the frequency. This is what the program is doing So it has four lines and this all the program is doing so the intent What the program is doing is very clear by looking at this program. Okay, but If I write a longer function and then put in uh, how the words are read and how Word frequency is computed right here in the same function, it becomes too difficult to understand why someone is doing it Now, you know, they're reading word frequency or computing word frequency I can go to word frequency function and figure out, uh, how it's actually being done the implementation Uh, the implementation and the intent can actually be separated the how and what it's good to separate those two things Uh, uh together So now that's I think, uh, uh The things that I want to mention about the writing beautiful core and this is a quick summary of what I've covered so far So choose meaning variable names. Uh, I can't stress enough how important it is It sometimes takes long a lot of time, but uh, it's uh, it's worth spending the time because uh The amount of time we spend later trying to figure out why the program is written like that Or trying to figure out how how this actually working Uh, uh, is a lot more if you don't spend enough time early to pick right variable names And use comments when required, uh, but don't put comments just because you have to Split the program into small independent modules and functions Avoid duplication at all costs Supposed implementation details and always optimize for readability Let me stop with a quote from tower programming Uh, a program should be light and agile. It's subroutines connected like a string of pearls So talking about the elegance of the program Uh, the spirit and hint of the uh program should be retained throughout Should have very the clarity of that you should have in the program There should neither be too little not too much neither needed loops nor nor useless variables There's a lack of structural rigidity and also need to have the right balance the program to make it beautiful Happy coding and I'm open for questions The slides of the talk are uh on my twitter feed if you can find out if you want to follow that I'm open for questions. So any Please uh for the mic Hi, um, so when you talked about the number of Objects that the human brain can track What's your opinion on the sort of recommended maximum minimum length of a code block? Sorry The the sort of recommended length of a code block So there's there's a school of thought that says if a code block is larger than n lines It becomes hard to read where n is said to be any number between 40. Yeah So I think thumb rule is it shouldn't be more than uh, half a page of sheets I think is what people say, but uh, I would say when my usual recommendation is not more than uh, uh 10 lines is what maximum I would say for a function So I would say like the 7 plus remains to rule it works for even number of lines in a function What are your thoughts on code formatters like yapf? So could please repeat I couldn't what are your thoughts on code formatting tools like yapf? uh, so Uh, I think it's uh, uh, I think let me repeat. So you're talking about the go for my tool, right? Yeah, I think it's a really good tool Uh, I think it's called the the bike share discussions I should be use one spare or two space or put a space before or after I think we just Uh, get used to whatever it is and I think go format go has really done very good thing about Uh, how you don't have options. You have just follow just one formatting thing But I don't think we have that luxury in python though. There's perpet It's up to the people to decide whether to follow or not I think it I would really love to have something like that for python So just a quick question on your thoughts on uh Something more specific about intelligible variable names Uh, I how I agree with most what you said. I think it's right I just wondered about this habit of deleting all the vowels in variable names like trying to Like picking a name and then abbreviating it by deleting all the vowels like I hate this. What do you think about it? this practice Oh, sorry. I didn't get good. Please repeat the question. Sorry. Yeah, so this kind of habit of deleting all the vowels and variable names once you've chosen a name that uh to try and make it shorter like some I guess there's a trade-off between variable length and intelligibility Yes, uh, so I think it's an important point. So I would say the variable the length of the variable should be proportion can be proportional to The scope of it is okay So for example, if it's a local variable if you have a function Which is five six lines doesn't make it. It's probably okay to have a single letter variable But whereas if you have a global variable, uh, which the scope is much larger It's better to be verbose and have the full name So if it is just a small function or inside of our loop, uh, I would say for w in words W kind of indicates it's a part of uh, it's an element of words. So that's a single word So that's probably okay to have a single letter, but I don't really like to Take out ovals or kind of make it Short just to uh I think readable is more important than the length of the variable. That's what I would say Thank you. I'm not in your opinion. What is a good time to clean up your code when programming? uh, I would say, uh It it's it's a it's a habit that you have to build over time. Okay. So, uh Uh Once we start keeping these things in mind when you're writing code or looking at someone's code You kind of feel that it's kind of violating that principle. Okay, so we should start getting that sense of Uh, identifying that bad smells so that when you're writing your code, you don't actually write that kind of things. Uh, so, uh, I mean probably when you're beginning Uh For a big nuts, it probably takes a while to get that habit. So we'll write it and then clean up But uh once you get through that go through that habit, you'll probably uh start getting that sense It kind of becomes your habit. I believe Any more questions? Okay, so thanks a lot and thanks


Did you know that you can drive inbound phone calls and only pay whenever your phone rings through Google? Bet you didn't know that or if you did, you're smart because that's a possibility. You can do that. It's called Google call campaigns. So if what you want is inbound phone calls as an insurance agent, all you got to do is sign up for the Google call campaigns, a Google product. It's something we do predominantly for property and casualty insurance, but it is a huge, huge portion of what we do is inbound phone calls. So if what you want to do is get phone calls to ring to you, then man, there's a product for you as an insurance professional and I'd love to talk to you about it.