Hi, welcome to another Dev Nation Live, I'm Adsonia Naga and I'll be your host today. And I'm very happy to have my dear friend Sebastian Blanc today to present something cloud native and how can you secure your microservices. So Sebi, thank you very much for joining us directly from the beautiful city of Nice in the south of France. Sebi, the stage is yours. Thank you a lot, Adson. It's an honor to be introduced by you. And I'm really happy to give this session, it's always special to give a live session like this. Especially, I would like to thank first my daughter because I had a huge laptop issue and she borrowed her laptop, so I had to install everything on that. It's working perfectly, so it will be fun. Today we're going to talk about security. It's really short 30 minutes. I hope to show you a lot, not so many slides, a lot of live coding. I tried to cover many use cases and then we will have time for questions. So let's switch to my screen share now and here we go. Let me share, let me go to my slides. Okay, so let me talk a bit about security and more specifically about how you can secure your microservices in a cloud-native environment. Yeah, that is a lot of buzzwords, okay? We're going to use Keycloak for that. So I haven't time today to give you the whole big picture of what Keycloak is, but Keycloak is an identity user management server. So basically, it takes care for you of all your user management, your authentication flows, your authorization flows. You don't have to care about that anymore because Keycloak does that for you. You downloaded, you unzip it, you start it, you put some configuration and then you can secure your web apps, your backend sources and let's focus on that today because in a cloud-native environment you could have, well, let's say a Spring Boot microservice deployed, a service, a Node.js service deployed, a Quarkus app deployed, maybe even go microservice. And all these different technologies, you want to secure them in an easy way. And with Keycloak, it's possible to do that in an easy way. So basically, how does Keycloak work? Keycloak is based, it's using heavily the OpenID Connect protocol, so most of the time you access your web application and that is where you will log in to the Keycloak server to obtain a token and with this token you will be able to make a request to different services. When you get a token, and we won't spend too much time on this part because it's not really the topic, but once you log in in your web app, Keycloak will give you back free tokens, the ID token, which is a bit like your identity card, but then also an access token and that is the token that you will use to make secure requests to other services. This access token has a really short lifespan, around five minutes by default. And that's why Keycloak also gives you a refresh token that you can use to obtain a fresh access token. If we look at a monolithic application, I go to my server-side application, for instance, on my browser, and then I want to authenticate, I'm redirected back to the Keycloak where I enter my credentials and then there's the all off-float happening. Let's not spend time on that, but if everything is okay, the tokens are getting back to the web app. And then with this token, you can make some request to any services. So how does that work? So you can see here on the spectrum, the user has logged into his application and now he has an access token. This token, by the way, is a jot. We'd say that for JSON web token. That means it's a token that contains payload. It's a self-contained token. And with this token, it can call any service. And the service will receive the request and it will verify the token. And if it's okay, you can go on with the request. So what is exactly verifying a token? When your service receives a token, it will verify the signature, because when you obtain a token, it has been signed by Keycloak. Keycloak has a private key that you use to sign your token and your service has access to the public key. With that public key, it can verify the token. There are two ways to do that. One way is doing it offline. That means that when your service starts up, the first time it will retrieve the public key and then it can just verify your tokens without asking again Keycloak. But if you are in a less trusted environment, you can also ask your service to always ask Keycloak to verify the token. But be aware, if you do that and that you have a lot of requests, there will be a lot of requests to your Keycloak server. In most of the cases, the offline signature verification should be enough. Okay, that is for one service. But what if your service needs to call another service? That's what we see here. Well, that's the nice thing with this access token, service A, once you have verified your token, it can use the same token to call service B, for instance. And service B could be a completely different technology. Service B in its turn can also call a service C. And that is exactly what we are going to see now in the demo. I will have service A, which will be a Quarkus application. Service B will be a Node.js service. And a service C will be a PHP, yes, you heard as well, a PHP application protected by a state card proxy delivered by Keycloak called the Keycloak Gatekeeper. How do you make such a request? Let's see some simple codes and then we switch to some live coding, okay? So the first case, the most common case is once you have logged in to your application, you're in your web app and you want to call a service. So here's some JavaScript. How do you make a call with JavaScript? That's plain vanilla JavaScript. It's pretty easy, you start a new, you make a new agent request. And the only important thing here you see is in the third line, you have to set a header called authorization, and then the value is always bearer, space, Keycloak, token, your token, your access token, okay? Let's see another example. For instance, if you are in a Java application, this is more or less if you are in a servlet method, for instance, you are in your servlet method and you need to call another service, for instance. That's pretty easy with Keycloak adapters. You can obtain a Keycloak security context and from this context, you can obtain a token and then you just use any HTTP client that you want or REST client, doesn't matter, as long as you can put a header, okay? And the last example, which makes two technologies here, here it's a snippet from a Spring Boot application written in Kotlin. And here you can see with Spring Boot, we provide some nice features here, something that's called the Keycloak REST template customizer, it's just like a regular Spring REST template, but it takes care for you of putting the token, the access token in the header for you. So you don't have to take care of anything, here your customizer, your REST template, and here if you do a get to another service, it will just put the header for you, okay? So, enough talking, let's move to some code and some demo. I have a really simple web app here, really simple, it's just some HTML and some vanilla JavaScript, and all I have done here is adding the, as you can see here, the Keycloak JavaScript library. And on top of my page in the navigation bar, I will have here a button called login, and I just call the login method, okay? And that is the application running here, really simple app. And when I will click on logging, I will be redirected to my Keycloak server to enter my credentials. So let me click here on login, and here I'm on my Keycloak server. I'm not on my web app anymore. Here I can log in with a user I've previously created, Sebi, and I gave it password Sebi, and I just log in. And now I'm redirected back to my application, okay? And if I go to token here, I can see that I have my free token that I spoke before about. I got my ID token, and I get my access token. You can see it here in JSON format, and I got my refresh token. When I will make a request, I will use my access token, but I won't use it in this format. That is not really convenient to pass as a header, as you understand. So what I will do, I will convert it to a base 64 format like this one, and this is what I will put as value in any request I do, okay? Now, that is on how to obtain a token. Let's try now to make a service. So here I have a button, and if we go back to my code here, and we go to app.js here, we have the simple call, and this is just like the code snippet I showed you before, and I'm trying to call here localhost 8081 products. That service doesn't exist yet. We're going to write it from scratch. And you see here, I just passed the token. So if I go back to my app, and I try to make the service call, nothing happens. We can even see that on the inspector here. If I do my service call again in the network and I do a service, it fails because the service is not present. So let's create from scratch our first service, okay? And for that, we will create a Quarkus app. For those that don't know Quarkus, Quarkus is the latest coolest Java stack to create application, Java application for the cloud, really low memory footprint, really fast and amazing developer experience. And that's why I can do it live from here.  And here I say create a new app, and here I will have some questions. So let me see, how, let me set the package. So it will be org.savvy. I will call it the product, okay? Oh, the product service, sorry, product service. Version one is okay. Yes, I want the rest resource, and it will be called org.savvy.productresource, okay, and the pass will be products, okay? And now I have created an app, an empty app that just contain one rest resource, and I can just open this in my IntelliJ, okay? So let's go to IntelliJ, and let's open this application that I just created. So here I go to destination, and I see here my product service. Okay, let's open that in a new window. Okay, here we go, and it will just load my project here. It should take a little, okay, here we go. And if I go to my main source Java, I take a look here, oh, I'm clicking too fast, org.savvy.productresource. Let me make this a bit simple, a rest app. I could run that, it could work. But what we want here is to add some key cloak and make a secure rest endpoint. So the first thing that I will do is add some extensions. Extensions in Carcass are like plugins to add new features to your app. And I need two extensions here for my app. The first one, I need something called rest easy json b. Json b, because I will manipulate some json, I enable auto-import, okay? And the second one that I need, of course, is key cloak. Oh, let me add here Carcass slash key cloak. Okay, and that is all I need. And now I want to create a secured resource here on the path products. And let's make a method called get products. Here we go. And it will just return for me a list of products. So let's do it. Let's return something called arrays as list. And here I pass my product. And let's pass another product, like other product. Okay, here we go. And here I need to change this to return a list. A list of string. And I'm almost done. I need to specify it's a useful list. Okay, here we go. And now I want to secure that method. And that is pretty easy here. I will just say roll a load. And here I say that only authenticated users that have the role user and my user savvy that we, for which we obtain a token has the role user. So that will work, can access this method. Okay, and well, I'm already almost done. I just need to add some properties in a property file here from Krakus. And because it's a bit boring, I have a template for that. But let me go through it, pretty simple. Here I say where my keycloak service running, the name of my service, and only which will. Okay, that is all I've done. Remember, completely from scratch. Okay, let me just, you should not do that at home, delete the test because I changed the resource and by default my test will not pass, but okay. And now I can run my app. So let's go back to my console and to my terminal. And let me see. I'm just sorry, I'm stuck. I'm not used to use a Mac. So let me see here. Okay, let me close this one. And I just want to move to, oh yeah, here we go, sorry. And here all I need to do is maven package, package Krakus, let me call on Dev. And that will package my app and run it. And it's failing. Oh, I forgot to go in my, I was not in my project. So here I'm in my project. It will package that as a drawer and it will run it and then my service should be able to access it. Okay, so it's taking some time. On my computer it's faster. That's just a small MacBook Air for my daughter, which is not the fastest. But believe me with Krakus, your app should start in less than a second. Okay, here we go, it's running. So it started in three seconds. Yeah, that is a bit slow. We can just make sure here if we go to my service, localhost 8081 slash products, I should have an error, not authorized. Okay, so that means that my service is secured. But now my app here, I still have my token. I should be able to call my service. And this time it should return some results. And here I do my service call and of course it's not working because I have a demo effect. Like I'm not sure why. Oh yes, no, no, no, no. You know what? It was part of the demo. It doesn't work because I have course issues. I need to add a course filter to my app. And that is a great opportunity to show you that I can fix that in my Krakus app without even stopping the app. So let me go back to my Krakus app, which is here. And just while my app is running, I can just create a new class. Let me create a course filter class. Okay. And here again, I'm using a template because it's easier. Pretty simple course filter for those that knows course. And here I just save it. And now if I go back to my service call here that I call it, I should now be able to make a call. Let me see. Here you see my products, it is working. So, and if we take a look at the call here in the preview in the header, you can see that I pass here the authorization header. Okay, so that was the first step. Now I want my Krakus app to be able to call another service and it will be a Node.js service. A really simple service that just returned an additional product, okay? But let's first fix that in the Krakus app so that we can make a call to another service. Let's go back to my code. Here we go. And what we will do first thing is we need to add a REST client. And this REST client, it's called, here we go, and I paste it, sorry. We'll see, oh, oh, it's gone. I do control its command. I'm on a Mac, of course. So, it's Krakus, a small REST client, okay? And with that I will be able to, here I made typo and here we go. Small REST client. With that I can create a simple REST client to call other services. For that I need to create an interface. So, let's create a class called premium. Premium service, okay. Premium service, okay, here we go. It's an interface, here we go. Let me make it a bit bigger. I just need to annotate this as a REST client. And also, I need to register the client headers. I will explain you that later. That is to propagate my token. And I need to provide a pass. And the pass will be something like, let me see, it will be something like premium slash products. Okay, and here I need to import this, okay. And it will be just a simple returning a string, something called get premium. And it will be, oh, and it will just, oh, sorry, now it's an interface. I don't need to implement it. Sorry. And that is all I need to do, get premium, get string, okay, here we go. And now, in my product resource here, I can just inject my REST client. So, I'm going to name it as REST client. And it's my premium service, premium service. And here, I can just do string, premium. And I do my premium service. Get premium, okay, here I need a semicolon. And let me add the premium product here to my list. And here we go. And last thing I need to do is to add some properties again. Here, let me again use some template here. Here, I just specified where my REST client should consume the service that is on local host 3000. That is where my Node.js service will be running. And the other really nice thing here with Quarkus is that you have something called propagate headers. And here I said, when you receive a request with the header authorization, just propagate this header in your REST client. So, I don't have to take care of any access token to be present, it will be done for me, okay? And that is all I need to do, okay? So, let me just go back here to my app because I added a dependency, I just need to run it again. And while it's running, let's move just for a while to my Node.js service that we are going to consume. So, with Node.js, you have a key cloud module called key cloud connect. So, you just add it to your package JSON and you declare it here. And then it act as a middleware for Node.js Express. It's pretty easy to set up. Let me skip that because we are already a bit late, but what is nice here, when I define my Express route here, so on premium products, I just need to pass it as a middleware. So, here I say key cloud protect, the user should have the wall user. And here I send another product back, premium phone, okay? So, let me start this app. So, let's start in debug mode, should be fine, I think so. So, here my Node.js app is running and let's make sure it's running. So, if I go here to 3000 slash premium slash product, oh, it's good, okay, it's complaining because it doesn't have any token, which is perfectly fine. And it gets here and acts as deny. So, my Node.js service is now protected. And if I go back here to my app, now if I do my service call, I should have a third product coming from my Node.js service. And let's hope the demo gods are on my side. And if I call here my products, well, I'm not lucky because it's complaining because what is happening? Oh, you see, I maybe missed something. Then, that's public, could not find a method for abstract get premium. Okay, so let me just go back to my code. I maybe had done something wrong here. Let me check premium service, get premium, premium service. Res client get premium. I don't see anything. I just take a look on my backup, which is on my other computer because I really want to show you that premium service. Oh, yes. I did the wrong annotation here is register res client and not west client. Sorry. Okay, here we go. That should be the better. And again, I don't think I have to reload. And if I go back here, it's still complaining. So, maybe I need to reload and let me just break this and run it again to be fast. Here we go. Let me just make sure I haven't missed anything. Premium products, okay. Let me see my properties are through it. That looks okay. Or SEBI looks fine. Should be okay. Okay. And let me do your service call. And it's not working. And I don't know why that is not funny because it worked working just before. Could not find a method for abstract get premium. It's so, oh, sorry, sorry. I know, I know. I need to clean here. Clean because it was still packaging without recompiling. Yeah. I wanted to be too fast. I'm sorry for that. And let's make a last attempt. And otherwise we will move, well, we are close to the end already. But, okay. So, here we go. And just let me sure, let me log in, log out again. SEBI, SEBI, here I log in. And here I go to my service call. And I call my service. And it is not working. I'm so, so sorry. I under the stress. I probably missed something. Public. Oh, sorry, I know it. I'm typing way too fast. I, yes, public. You know, I'm a old string. Oh, get premiums. That should be good. I don't know what. Oh, yeah, yeah. Sorry, sorry. I'm really, really too fast. Let's just finish that because I really want to show you that. Get, I forgot some annotations. And I need to produce this. Here we go. Application text. Okay. And that should work maybe without a reload. I'm saying that several times already, but this time let's, because our thing is at the torque. Okay, here we go. We see I'm happy it's working. So here we got my two products from my Quarkus app. And this one comes from my Node.js app. Okay. Took some time because I was not typing good, but that's it. Let me see. I, do we have a hard stop or can I show a last thing? I don't know if someone from the staff can tell me that because there's a really last. Yeah, maybe you should. Sorry. Can I go on for two more minutes? Yeah, okay. I, let me just check here from staff. Can I go on for a while? Yeah, can anyone go ahead? Okay, let me just show you the last part. So because I want to go a step further. I want to also change my Node.js app, so it can make a call to a third app. And I told you it can call a PHP service. And for that I'm using something called HP Propagate and Request. HP Propagate will just make sure to propagate my headers as well. Okay, that's like what we did for the other app. So let me just do this really quickly, HP Propagate and here and just instantiate it with this. And here we go. I need to provide just an headers to propagate, okay? And here I pass just a small stuff like, well, what do you want to propagate? Is my authorization header. Okay, authorization header, that should be okay. And then if I go here back to my method, I was smart enough to command that out here. And here I call here my PHP service which is behind a proxy and that should be okay. So let me restart my app and let me start the proxy that is behind my PHP service. We don't have time to see exactly how it works, but now if I go back here, let me make sure my PHP service is there, secured. Yeah, that's great. I got a 401, that means it's secured. And now if I go service call, I should have, yeah, here we say. So let me zoom in. My products, other products and my Node.js service is calling the PHP service. And yeah, I forgot to change the string, but this last string here is coming from my PHP protected services. And that is really what I wanted to show you. I don't have time to show you the authorization part that will be a next destination session, I guess. But at least we saw three cloud native technologies, Quarkus, Node.js, and a Go proxy to protect any app, how you can put that in place to secure a whole set of microservices with key cloud. And let me go back and I'm now going to stop the screen share and go back to a video, so if the stuff. So yeah, that was really quick. And let's, I hope you enjoy it. I will, there are some resources of the demo which are already available. I will share that, I have a complete worship around that, that this take more time than this 30 minutes, but I will share it with you. And let's try to answer some questions. Epson, you going to help me for that? Hey, I see Bird, but it's Epson. Let me just drink some tea. So we have a lot of questions I see. So that is some comments. Have we selected some questions? Oh, Epson, have you selected some questions? Oh, apparently Epson is from mute, but I'm looking. Are the code shared on this session answered? Yes, I will share it. The example, yeah, all the example that I showed you will be shared. What can I see here? Can Keycloak run on OpenShift? Yes, of course. Here for demo purposes, I didn't run it on Keycloak, but I didn't run it on OpenShift, sorry, but yeah, we are working really well on OpenShift and with the next OpenShift, there's a really nice stuff coming around Keycloak and operators, which will make it so easy to deploy to upgrade your Keycloak server. So yes. Will there be a recording? Yes. Thus, free skill, yay. All right, hello, now I'm back. I had to refresh. Oh yeah, I'm back. Unfortunately, we ran out of time and we had a lot of questions in the session. First of all, thank you very much for the nice demo. We know that live coding is very hard. And what we can do is that we're going to take all of the questions and send to you. Maybe you can share it later on the YouTube video link so the audience can get kind of answers. And again, I would like to thank everybody that was watching. Thank you, Sabi, for this simply awesome presentation and see you on the next definition live.


A group of Nigerians under the ages of coalition of civil society organization and political parties for good governance have stormed the European Union office in Abuja to protest against its report on the February 25, 2023 presidential election. The protesters, who were seen with several placards bearing different inscriptions, marched through the central area to the European Union's headquarters in the federal capital territory. The EU, heard earlier in its report, faulted the 2023 general elections, stating violence, killing and vote-buying as some of the factors for its criticism. The peaceful march, terminated at headquarters of the EU, where leaders of the group addressed officials of the Union. With a promise from an EU official to relay the message of the protesters to the Union, the group took their leave. We have come to register unequivocally that we are not satisfied with the report of the European Union. As a matter of fact, we have the opinion that the report is not just ridiculous, but a deliberate act to slight the Nigerian entity, and of course, by implication, our leaders and the government of Nigeria. Particularly now that we are grappling with fundamental issues of insecurity, there is no way the European Union will beat her chest and say she's in love with Nigeria and she's in love and seeing the progress of this country and also at the same time come to add salt to injury. It shouldn't be.


Hello, hello, hello, everybody, and welcome to the financial modeling webinar series for Dubranca Consulting's financial modeling webinar series. And today we're going to be talking about key steps to revenue and cost modeling. So introduction, we talk about profit revenue costs, break-even analysis, simple steps to revenue cost modeling, and then we do a demo, and that is it. And we talk about the financial modeling institutes and their certificate program. The next exams is in October. So we just have a brief talk about that as well. Right. So why do people go into business? I can see some people have already written that to make profits, to create value. Which one more? Is it more to make profit or more to create value? Which one comes first? Do you go into business thinking, I want to make money? That's why I'm going into business. What do you think? Most businesses, owners enter into business to make money, to make a profit, really. Now one thing is this, even if it's not a business, you have to make a profit.   You need funding. And if your expenditure is more than your funding, you can't survive. So even NGOs really need to make a profit. They don't call it a profit, call it excess revenue over expenditure. They need to invest so that the investment income is what sustains them. The Nobel Prize is mainly the investment income from Alfred Nobel's investment or his net worth then. I mean he invested it. And is that investment income that sustains the Nobel Prize? Not the main principle of the capital. So yes, you need to make a profit. You need to make a profit. Right. So if you want to really make profit and really make money, you must be solving a problem. So yes, you're into it. You need to make a profit to survive, even if it's not to just enjoy yourself, but you need to make profit to survive. And if you're solving a problem, well, that's your business is very sustainable because you're actually solving a problem. Right.  Like most people in entertainment, they need to make money as quickly as possible because after a while, the next new thing or the next big thing will come across and come along and they stop making money. Yeah. Right. So profit is the main reason. Yes, we agree profit. But there are four types of profit. The profit is in the PNL. So it's the PNL that has profit, but the PNL has various levels of profit. I mean, you have gross profit. You have operating profit. You have profit before tax. You have net profit. So gross profit, we call it the line in our training to say that's the line. So gross profit is the line. We now have above the line and below the line. If you fail at gross profit, you are really almost dead. Now what I always say is in accounting, right, you start with revenue and from revenue is like when money comes in, then below revenue, everything below revenue is different people eating. Yeah. So you've come to eat. So the company is there and people have to eat in different levels. Why am I using eat you? See soon. Before gross profit, there's cost of goods sold or cost of sales that eats first, right? So those things directly related to the sales eat first. Then after gross profit, what do you have eating? You have things like selling general and administrative expenses. You have the depreciation, the portion of the asset you use for that particular year is put in as depreciation. All those directly related stuff or supporting stuff. We just call them SG and A. So then you now have your EBIT. After that, which is also called operating profit. Then you now have after that, you have interest income and interest, interest income. So interest, interest expense, really not income, mainly interest expense, usually a net expense of interest. That's when you're paying your financiers, whoever is financing the business, you have to pay them. Then you now have earnings before tax after that. So earnings before tax, after you put in interest, then you now pay the government. You pay the government. That's tax. And then you have net profit or earnings after tax or profit after tax. That's the only time that the shareholders can eat. That's why I guess it's called eat earnings after tax. So shareholders can now have their own meal. And what do they meal? Do they get from the P&L? They get dividends. So yes, I know accountants don't write it in the P&L, but really you remove dividends from the net profit. And then what you have after that is called retained earnings. And that's what you retain in the business, but the shareholders have the right to take everything. They don't need to retain a dime, but that's not really good, is it? So they take their dividends and that's it. So this is your P&L. This is a typical structure of your P&L. Right. But so your revenue and your costs. Now the issue with revenue is revenue has different names as well. Accountants call it revenue sales turnover. So if I say turnover or sales or revenue, I'm saying the same thing. Accountants have different names for many things. Different names. I mean, we used to call stuff fixed assets in the balance sheet. Now they call it what, non-current assets. So different names. Profit after tax is the same as net profit is the same as earnings after tax. So when you hear earnings is profit. If you hear earnings also sometimes people call revenue earnings. In fact, they even call it earnings. So accountants, please choose one and stick to it. Then so for what is revenue? Revenue really is price at times quantity. That's what revenue is. So when you're building a model, when you're building a model and you want to build a model for revenue, you need to understand what is price and what is quantity. And then also say, okay, for price going forward for the next five years, how will price change for each and every product? So a simple company, let's just say has one product. So this price, how's it going to change over time? Is it going to grow by inflation? But really, competition will have something to do with it.   Now you hear about price wars. Price wars are maybe a very, very strong competitor who has some cash. Maybe some cash reserves. We decided to crash the price so that everybody else in the market will die of complete asphyxiation here. So yeah, if you've crashed the price, let's assume you're selling bread.  And typically the cost of producing bread is five naira. Let's just say five naira is the cost. And you have crashed your selling price to four naira. What that means is you're losing one naira for every loaf of bread. Now, if you have enough cash reserves, you probably can survive that for a couple of months. Maybe other people can survive it. So what you're hoping is I will try and survive it for five months, but everybody else won't survive it and they will all die as a business. And then guess what you do when they all die? You now hike the price up to ten naira and make a killing. So those are price wars and it's really unethical, but well, there's business, right? Some people do it. So that's price, so price times quantity. So price, modeling price, what are the drivers for price? I've just given you so many drivers. There's inflation, there's competition, there's costs, different drivers. So you decide what are the drivers you're gonna use in your model and then you model what price will be for each of your products going forward. So what is my price per unit? Quantity on the other hand also has to be modeled. How do you model quantity? So someone has a question, how do you model quantity? So how do you model quantity by, say, okay, I am producing.  How much can my machine produce? So there's a capacity utilization issue there for a manufacturing company. What about if you're not manufacturing and you're trading? So they're trading, who is your supplier? Who is supplying you this quantity of stuff you're selling? Can you increase the quantity that you buy from the supplier so that you can sell? Or is it scarce good that you can't increase? So no matter what, you can't grow. So when it comes to growth in a business, really, I don't really check revenue to check growth, it's better to check quantity. Cuz if you check revenue growth, revenue growth could just be a matter of price. They've just increased price and then they're growing. So you increase price from 10 hours to 20 hours. With the same quantity, you would definitely have revenue growth. But your business really hasn't grown. You just increase the price, yes, revenue has grown. So quantity is a very good determinant of growth. Are you selling more? Then you're growing. But of course, price, a lot of things affect price. Quite a few things also affect quantity. So price and quantity is the mix. Your costs are very, very critical. And what determines their cost? Very importantly, your costs are determined. If you want to really model accurately, you don't model for the P&L sake where you have your cost of goods sold. And then you're selling on general expenses. You should model based on fixed and variable cost. Okay, so yes, it's very important. Fixed and variable cost modeling is very critical. So your fixed costs, these are costs that you incur regardless of whether you produce anything. So if you really, someone says, how do I identify my fixed costs? To me, the simplest thing is this, have a brainstorming session. And ask yourself, if we sell zero, if we make zero revenue next month, we make absolutely no revenue next month. What cost will we still have? So as a business, what cost will you still have if you make zero revenue? So just check, you definitely pay salaries.  Maybe there's a bonus aspect of salary is related to revenue or related to sales. You would pay that bit, but you pay salaries. Your generator or your lights will still be on. For those joining us from abroad, we use generators. We don't have power that much. So yes, you either pay the power, whatever source of power, you have to pay for that. You need power regardless of whether you sell, right? And so there are various costs that you will have. Maybe you won't go with your car. You won't do, well, you may do marketing because obviously, you still want to make future sales.  So obviously production costs, you're not producing anything. So if you're not producing anything, then you're not increasing to your stock, you won't have those costs. So the fixed costs are the ones that will still remain if you make zero revenue. What about your variable cost? So your variable cost, well, those are the ones tied directly to the quantity of stuff you're selling. That's the goods or services. You're selling a service. If you sell a lot of that service, yes, there's cost related to that sale, that cost is variable cost. So if you don't sell, you don't pay anything, that's what we call fixed cost. But if you're selling and there's a cost to that sale, it's a variable cost. So it's tied to the quantity of goods or services you are selling or producing, right? So that's variable cost. Now, you need to understand the formula, right? So if your total cost is fixed cost plus variable cost, then that's your total cost. Now let's determine how we can calculate like a break-even point. How do we calculate a break-even point, for example? There is UVC, what's UVC? UVC is unit variable cost, unit variable cost. So your unit variable cost and your quantity, if you multiply your unit variable cost times the quantity that you actually produced, that's what you get as your total variable cost, right? So that's your total variable cost. So what's break-even? But there's a formula to it and the nice thing about modeling is you need to kind of break things down into formulas. And once you have the formula, you can now use it in the model, which we're gonna demo. So we're gonna do this together, guys. And there's break-even price and then there's break-even quantity. So how much do I need to produce so that I make zero so that I can pay all my expenses, everything is fine, I make zero. Then I know from then on I'm now making money, yeah? Right, so let's see. Break-even analysis, representing the level of sales needed to cover costs or total costs, fixed and variable. You're covering two types of costs, the fixed and the variable cost. So in a nutshell, break-even is when profit is zero, exactly. When profit is equal to zero, you have broken even. And depending on how much fixed cost or how much variable cost you have, it depends on how well you're gonna make profit after breaking even. So the speed at which you're profitable after breaking even is dependent on how much, what is the proportion of fixed variable cost you have? There is something called operating leverage, operating leverage. You guys should check it out, it's very, very key. Now, everybody knows about leverage. When you buy, you only go to the bank and you get a loan and so on. But operating leverage is one of the best-kept secrets of making a lot of money. And also, best-kept secret of losing a lot of money. If you have high operating leverage and you're a profitable company, you'll be more profitable than a company with low operating leverage. Now, what am I talking about? High operating leverage means the proportion of cost fixed variable, fixed is more than variable. Fixed has a higher proportion of your cost than variable cost. So that means you have high operating leverage. So you make far more money when you're profitable, when you've crossed break even, you make far more money than someone else who has more variable to fixed cost, yeah? Yes, so here is proportional fixed variable cost, nice. Okay, let's move on. Break even quantity, how do we derive it? So if your profit is zero, then profit equals to revenue minus total cost, yes? Profit is equal to revenue minus total cost. That's the first basis, right? Your profit is zero means that profit is equal to revenue minus total cost. Now, if your profit is zero, that means profit equals to rev minus TC. We just summarized it like that, isn't it? Therefore, rev is equal to total cost. So this just, we're deriving break even quantity. So if your rev is equal to total cost, that means your rev is equal to price times quantity. Remember, your total cost will be the price or cost price, right, times your quantity. So your price at break even is your break even price as well. So it's like your break even price times quantity. That's what your revenue is, that price, your break even price. And break even price is the price at which you break even, isn't it? So let's see.  Your total cost is your fixed cost plus your variable cost. Then we're saying that your variable cost has to be your unit variable cost times Q because we've already said your variable cost is UVC, unit variable cost times quantity, isn't it? Because your revenue is price times quantity, right? And you're saying your total cost, if you look at the top here, we see revenue equals to total cost. And if your revenue is price times quantity, and then your total cost is equal to fixed cost with variable cost, and your variable cost is equal to unit variable cost times quantity, then your price times quantity will be equal to, that is your rev, right? Your price times quantity is equal to your fixed cost plus your unit variable cost times quantity. What we've just written up here, down here, is the exact same thing we wrote at the top. If you look at it, revenue equals to total cost. But if you're in the break even, your revenue is equal to total cost, that means you've broken even. But your revenue is price times quantity, and your total cost is fixed cost plus variable cost. But your variable cost is unit variable cost times quantity. So this is the formula, this is the main formula. P times Q equals to fixed cost plus unit variable cost times quantity. Let's keep driving. So if you put fixed cost to the left, you know all this you did in primary school, subject of the formula kind of stuff. Fixed cost to the left, that means what you have to the right would be price times quantity minus unit variable cost times quantity. You can see quantity is there twice, isn't it? So your fixed cost, you can take quantity out, and you now put your price minus unit variable cost in bracket because quantity is in both sides, isn't it? So fixed cost equals to quantity open bracket price minus unit variable cost. Continuation, quantity equals to fixed cost divided by price minus unit variable cost. So your break even quantity, that's what it is, isn't it? Break even quantity is fixed cost divided by price minus unit variable cost. Does that make sense? How does that make sense? You could take a picture if you like of it. It makes sense, take a picture of your screen and see if you can break this down and understand how you derive your break even quantity. So I'm going back to maths for you guys. Modeling has so many, modeling has maths, different things that you get to be in a modular. It's not that, in fact, I had a very short video, maybe I'll play it for you about who really is a financial modular, right? Let me play that video for you. So who is a modular? I'm a financial modular and I've been building models for deals for quite a long time. Over these years, over these years working as D Brown Consulting, we've basically built up a methodology, detailed methodology on how you build models, how do you consider yourself a modular? For example, I mean, someone wants to build a model for a telco or you want to build a model for an oil and gas firm. It doesn't matter what organization, what industry it is. As long as you understand the mechanics, as long as you understand how to sit down with the financial controller, for example, and understand the drivers of this deal, you will be able to build any model. So you're going to build models from scratch, in our courses, you build model from scratch, from a blank spreadsheet, all the way to a detailed model with sensitivity analysis, scenario analysis, all the ratios you can think of, DuPont ratios and the likes, detailed analysis that helps management make decisions on whether or not to go in with this deal or whether or not the firm needs to kind of change their strategy, all sorts of decisions are made with your model. And guess what? There's also a certification, an internationally recognized global certification now. Yes, you can get advanced financial modeling certificate and you do the course, you do the course, you get ready for the certificate, you do the international certification and you have your certificate, which is recognized worldwide. So come on over. You could send us an email at training at dbrownconsulting.net. We could go to our website, dbrownconsulting.net or just call us on 0700 training. That's plus two, three, four, 700 training or in Nigeria, 0700 training. So we're looking forward to seeing you. See you in the next class. All right, so let's move on. Let's derive break even price. Okay, let's derive break even price. So if break even price, so your profit is equal to zero, that's break even, profit equals zero. Revenue is equal to total cost, that's when you break even. So what's our break even price? Price times quantity is equal to total cost. If your revenue is price times quantity. So price is quantity equals to total cost. Now your price is equal to total cost divided by quantity. That's it, simple, right? Price equals to total cost divided by quantity. That's your break even price. Well, so simple steps for revenue cost modeling. Now I think it's time for demo, really. So time for demo, let's see if we can jump into demo. Okay, so I'm gonna, we need to, first thing we need to do is read this thing and extract the main information. So let's go there, let's go there, Incorporated is a consumer electronics company. In 2016, it sold 1,000 stereo systems for a total cost of sales of 4.5,000 stereo systems for a total cost of sales of $4.5 million. During that year, 30% of cost of sales were classified as variable cost and the remainder as fixed cost. Right, assume that over the next five years, cost inflation is gonna be 2% per annum and sales volume growth or sales volumes grow at 3% per annum. So cost inflation is 2% and sales volume that is the quantity we are selling is gonna grow at 3% per annum. Also assume that sales price per unit is $5,000. Price inflation that is for the price is going to be flat at 3% per annum and the factory's maximum capacity is 1,150 units per annum. So all this interesting information we're asked to what is the current break-even quantity of a company? What is the current break-even price? What is the total cost of sales in the fifth year? What is the profit in the fifth year? Are we ready to go through this case study, guys? The first thing is let's get our input. So let's see, what are these inputs? Base, salary, let me see. Have your base, or base here, what's our base here? I think it's 2016, 20, 2016, base units sold. Base units sold is, let me just, let me type all the key things I think we need total, cost of sales, cost of sales. We need to know the percentage that's variable cost VC percentage. And then if we know VC percentage, you obviously know fixed cost percentage, but then let's say cost inflation. What else do we have? We have sales volume growth here, sales growth. So but that's just the volume growth. And then what else do we have? What else do we have? We have sales price, then we have price inflation, then what else do we have? What am I missing? Taking everything all done. What else do we have? Let me read it again. Price inflation, I have price inflation, I typed it just now. What is missing? Capacity, yes, exactly. Capacity, thank you. Capacity, so let's just say the maximum capacity we have. Capacity, excellent. So now let's bring in all this, these are inputs. Okay, these are inputs, so I'll make this a general input. Okay, general inputs, shortcut is Contrast Ship Tilda, base unit sold, what's the base unit sold? Base unit sold, 1,000 stereo systems, 1,000. Total cost of sales is 4.5 million, 4.5 million. Let me make this currency so I can differentiate what's currency and what's not. Set is dollars, make it dollars. What's this variable cost percentage, 30%. What is the cost inflation, 2% I think. Take these percentages, all of these are percentages. Cost inflation is 2%. Sales volume, what's that, 3% I think, yep, 3%. Sales price, or sales price, 5,000. That is another percent, that is the format is dollars, let's see. So that's 5,000. What else, the price inflation is 3%. Just gonna copy this here, inflation is 3%. Price inflation is 3%, maximum capacity is 1,150 units. So this is unit, so let me just do a trick for you guys. This is unit, so I'm gonna do a conditional. I'm going to do a conditional format so you see what unit it is. So in our conditional format, then an advanced format. So in conditional, I'm just gonna put units at the end of this so people know it's units and make it whole number, double quotes, units, double quotes. So it's a trick, but it's actually still a number in that cell by showing us units. So percent, percent, money. I kind of brush this here, base units. And this is our base here, okay. All right, call this one, put the custom for that one and say it's put year, double quotes, year, why are double quotes? Right, so we have everything we need. These are all inputs. Again, I always like to follow best practice. I'm just gonna come here and make this an input style. It's not a flag style, it's an input style. Where are you? Inputs, okay. I made it a flag style by mistake. Let me undo. Undo, come back and let's make you input style. So styles are very important when you build a model. Okay, so now that I have that, we're ready to build our model. We'll start with the calculations. There's some small calculations. The set we should do, the set we should do the variable cost calculation. Variable cost, variable cost. Oh, that's what I said we should do. But we need to know the current break even quantity and price. We need to know also variable cost. Obviously, we need to know the unit variable. You remember the formula, unit variable cost, unit variable cost, and we need to know the fixed cost. All right, fixed cost, fixed cost, fixed cost. I'll start with the fixed cost. I mean, it's simple enough. Fixed cost should be equal to, what's our total cost? So total cost minus the variable cost, whatever we get as our variable cost, we have fixed cost, right? So currently if there's no variable cost, fixed cost is everything. All this cost is fixed cost, but that's not the case. So what is our variable cost? But they said that as at this case study, as at now, right now, the variable cost is 30% of the fixed cost. I mean, 30% of the total cost. So this is our variable cost. So if that's our variable cost, that means our fixed cost is 3.1 million. So what's our unit variable? This is a very important calculation you need to do. Unit variable cost. So the unit variable cost is equal to your variable cost divided by, what did we produce? We produce the base units sold. It's 1,000 units that made that. So this is your key value here. You're saying it costs you $1,350 to produce one unit. To produce one unit is $1,350. But your fixed cost remains fixed cost for, depending on how long it will remain fixed cost. Your fixed cost only go up based on steps. It goes up in steps, maybe after six months, maybe some of those cost price go up. Sorry for that. So this is variable cost, unit variable cost. This is all money, right? I think. So let's make it money, currency, dollars, there we go. Great. So now to quickly build our model, let's just create some structure to this. So structure for our model, we'll make it 2016, let's say we're starting out at 2016. And then I'll go and say equals to this plus one, equals to this cell, plus one. I'll make this, let's just stop at 2020 one. And I'll just highlight this and make it just a normal style. And I need to reduce the size a bit so you can see everything. Great. So what are the fields I need? I need to know what my price inflation is so that I can get my price. That's very first step. I need my price, can't do anything without price, right? So I need to know my price inflation so I can get my price. And we'll start with our base year. So our base year is, in fact, I think I could just put this to the left. Let's just start off here so that this just becomes our base year, right? So this is our base year. So our base year's price is equal to this cell, right? So this is our base year. So if that's our base year and then the set price inflation is equal to, where are we? Price inflation, price inflation is price 3%, price inflation. So you need to lock this. So we can just do a permanent lock. Since it's just one single cell, make this a percentage style. Percentage style and we drag this to the left to just highlight contour R. That will give us our price. So our price will grow by equals to whatever the price is to the left times one plus our price inflation, right? So this is our price. We grow that to the right, contour R, yeah. Yeah. Are we all good so far? So then we need to know volume. So the next calculations are for volume. So let's say volume growth and you have volume growth and we have volume and there's a very important thing. I'll tell you how big a volume growth to be able to calculate volume but your volume should kind of be restricted by capacity. So there's a capacity restriction, yeah? So we can have something like capacity volume or capacity restricted volume. I don't know what to call that. Let's just call it capacity for now, capacity, right? It can be maximum capacity. Can be maximum capacity. Well, I'll explain that the capacity, you have capacity showing that they said in the case study, if you look at the case study, it says that the factory's maximum capacity is 1,150 units per annum. So you can sell more than that. So when we look at the volume, if volume grows more than that, then we have to restrict it. We have to restrict the volume sold to what it's actually possible to produce. If you can't produce more than, you can't sell more than you produce. You get, so it's a logic we're gonna put there later. All right, let's move on guys. So here we have volume and growth, volume growth. Click, click, come on, click. So what's our volume growth? Volume growth is equal to, where do we have volume growth? Sales volume growth, there we go. I think price inflation, I hope I picked the correct 3% for price, did I? Yes, I did. So we can lock this, I'm gonna F2 and F4, and then we take this to the right, R, and I make it a percentage style. So if that's our volume growth, what was our base volume? So our base volume was, how much did we sell? 1,000, I think, 1,000 units. Yep, there we are. So if that's our base volume, then our volume, based on the growth, should be equal to this times, one plus, in bracket one plus this, and it's relative reference, and we drag right, contour R, right? Now, what is our capacity? Let's check, can you see that? Capacity is 1,150 now. In the exam, quite a few people forget about capacity, and if you're doing the AFM exam, and you forget that, that's a, most likely you won't pass. So 1,150, so one, you can see that the 2021 is excess, is exceeding capacity. So we need to write a formula here to kind of stop it exceeding capacity. So you write a formula that says, you need to give us the minimum, right? Give us the minimum of the actual volume, based on growth, comma, the actual capacity, which is in our inputs. Now, it's a good idea to take this capacity and put it here, right? So they want to put a capacity by the side, then the formula is better. So I think let's bring in the capacity down here. All right, we link it here, and then we write our formula saying, it's equal to the minimum of this sales volume, and the capacity here. So this is a relative reference, and this has to be an absolute reference, or it can be a column constant, but absolute is fine. Right, so if you say the minimum, that's what we're getting. Now, another thing you should do probably is, because I don't think you can sell fractions of units, like see this 1092.73. So I'll add something else and make it just rounded, right? So we get the minimum, and then we're gonna round that minimum down. So we just round down, okay? So we're gonna round down. We're rounding down the minimum, and we're gonna round it down to zero decimals, all right? So I'm just doing two things there. I'm both giving the minimum and rounding it down because we can't sell a fraction of a product. At least I don't think we can. So here we say we rounded it down. Since we couldn't reach one unit, we rounded it down. One, one, two, 5.5, and we rounded it down, this is maximum one, one, five, zero. So if I change my units for some reason to maybe reduce my capacity to a thousand, a thousand units capacity, that means that we can't produce everything is, in fact, everything is just a thousand, which is ridiculous. We're not growing at all. So that's fine. So here we are. Next step for us is the key outputs. Key outputs. I'm gonna put the key outputs here. Key outputs. What are our key outputs? And remember, this is the model. So what are our key outputs? Let's start with, if you have your cost, we have our price, then we can calculate, actually the revenue is what we just have there. So we can't even put key outputs yet. So what am I doing? Key outputs are down there. So after capacity, I think we can call it sales units. Let's just calculate sales units, right? Sales units, even though we have capacity, this is really capacity itself or sales units. This is sales, this is really sales units, capacity restricted or something. That's what this is. So if we have our sales unit, then we can have our revenue. Yeah, we can have our revenue. But some people want very clean modeling. So if you want really clean modeling, you may decide, you know what, let's just have it a row. Some people are very, you know, want to have capacity in one single place because capacity can change every year, which is true. So your capacity could change. So we just want to fix our capacity. Don't give me many things inside one formula. Make your formulas simple. So we just link our capacity here. Where is it? That's this guy, right? And I'll just have the same capacity figure all the way because another model, your capacity could change. Every year, your capacity could change. So to add that flexibility, let's just paste it all here. I'm going to paste special formulas. So I'm going to modify our formula a bit here. So instead of looking at this capacity figure, I'm going to look at this capacity here. And it's definitely not going to be locked. It's just going to be a simple relative reference, right? That way we don't need this one. I don't need this. I'm just going to delete this. And then I take this to the right. So this is better. It's cleaner, nicer, better. Right. So next step is the revenue. What is the revenue then? I mean, if you have all these figures, revenue is simply equal to, if you have what we call the price, where's your price? If you have your price up here, that's your price. And then you multiply that by your quantity, which the quantities are sales, units, capacity. Your revenue should give you a figure. I need to increase our size. Increase the size of our columns. Here we go. Yeah. Uh-oh, not enough space, too much money. And more size. Adjust the book, click it, right? That's fine. So revenue is there. Five, three, four, five hundred. Like you can even calculate the historical revenue if you like. And you see that that's what gives it, let's make this equal to this. How much did we sell? Sold 1,000. So now we go to costs. This is our revenue. We go to costs. Cost is where it's really tricky. Cost, you need to have cost inflation. You have cost inflation. What other variable do we need? With cost inflation, we can now calculate fixed costs. And that cost inflation also affects fixed costs. Fixed costs will grow only by inflation. It's still fixed, but it's just growing by inflation. Then you have, you need variable costs. And then you have variable cost. Then after variable cost, then we can calculate our total cost, right? So this is where operating leverage comes in. So let's quickly do that. So we have our cost inflation. So I'll just link it, sorry for my slow system. Cost inflation, go up. Where's cost inflation? Cost inflation, here we go. So I can lock that. Then again, of course, cost inflation can change every year. So this could be inputs and AI. Well, I call it an annual inputs. It's not gonna be fixed. It could be an annual input. But right now, let's keep it fixed, yeah? Then we have our fixed cost itself. So let's get our historical fixed costs. What was our historical fixed costs? Scroll up. It's historical fixed costs to where we... Yeah, we calculated it. So these are our fixed costs that we calculated based on the current model. So if that's our fixed cost, then going forward, our fixed cost is gonna grow by inflation. So the growth formula, the standard growth formula, right? And then we grow that going forward over the years, right? To do the mouse thing. All right, then what about our unit variable costs? So we had a unit variable cost calculation already at the top. So my unit variable cost is this guy. Oops, sorry, this guy. Enter. If that's my unit variable cost, then my unit variable cost, that's my cost for every unit will also grow by inflation, right? So that unit variable cost will also get bigger by inflation. So I take that, drag that to the right. Click and drag to the right. There we go. Then if that's my unit variable cost, then what is my variable cost? Is my variable cost be what exactly did I produce, right? So for this base here, if this is my unit variable cost, we want to apply it by what we produce. What did we produce? Sales units. That's what we produced, right? So I can drag this to the right. So then if that's what I produced, no, this is my total variable cost, then what is my total cost? So my total cost is simply equal to your fixed cost plus your variable cost, isn't it? Your fixed cost plus your variable cost. And if you look at the case study, the total cost was 4.5, right? So let's just check. Let's check up here. What's the case study saying? Total costs. Where's total cost? Total cost was 4.5 million, right? 4.5 million. That's total cost. So we're fine so far, right? So far we're fine. So I can drag this all the way to the right. Now, once you have that, then what exactly is our profit? What profit did we make? All this work, did we make money? Are we making money or not? So our profit should be equal to our costs. In your modeling, you should use this fixed and variable cost process. So simply revenue minus your cost. And enter. And I drag that to the right. And now, if you remember your break even quantity, can you remember the formula for break even quantity? Cost to your total fixed cost, which is where it's our fixed cost, fixed cost. This guy. So fixed cost, yeah, 100% right. Divided by, when you put a bracket, you take your price and subtract your unit variable cost. That's your UVC minus, where is it? Where's your unit variable cost? Unit variable cost, right? So this is the break even quantity. At this quantity, 63863.01, right? But it's just 863, kind of. So we drag right. So these are not exactly rounded, but that's what it is, 851. So if your break even quantity, just take it that you're gonna round this down. You will not, you have a tiny, tiny, tiny loss, maybe 0.00 something, but you round it down. So 851, 840, 829, 818, 817. These are break even quantities that you have, right? What about break even price? Who remembers the last formula and we're done? What is our break even price? It's total cost divided by what? Total cost. So equals to price will be your total cost. Where's total cost? Total cost divided by sales units. People have given up on me, huh? How much did you sell?  If it covers it exactly, that is your break even price. At what price can you cover your cost precisely? So that's your break even price. So your break even price is this. So 4492. So you can imagine a very objective question. What is the break even price for 2020? What is the break even quantity for 2019? You need to build this entire model for you to answer that question, which is this and this, right? So that is how you incorporate revenue and cost modeling. And this is very important when you're building a financial model because now you can tweak it to do all sorts. You can decide for some reason that I want to make, I don't know, you want to make a profit of two million here. So you could do a goal seek, you could do an OTG. This goal seek, I want to make a profit of two million. It may not be exact, two, zero, zero, zero, zero, zero. So what can I change? Now that's where sensitivity analysis comes in. If you're interested, go to our YouTube channel and go and check for sensitivity analysis. We did a detailed webinar on sensitivity analysis. So let's see which one can we control here? Total units sold, not really. Total cost, variable cost, cost inflation we can't control is the country. Sales volume growth, we can't really control that. Sales price, technically we can if our competitors are not too, well, let's see. So let's say that click okay, and let's see what it gives us so that we can have a profit of two million in a year. So it's given us a profit of two million in the last year. How, what, if you look at it, come down, see? We have a profit of two million. It saves for that to happen. Our current price in year one or year zero should be what? What should our current price be? If I come up there, what did it change it to? So price should be 5,394.64. If you start at that price in the obeisier and start growing your price by 3% every single year and you make this your price with this price and all the other variables, you will make a profit of two million dollars. And really, that's how you build a model and that's how you incorporate revenue and cost modeling. Hope you guys enjoyed this webinar. Any further questions? Well, your capacity, someone says you could increase your capacity. Yes, exactly. So beautiful because you have so many variables you could tweak, tweak your capacity and see how profitable you are. All sorts of stuff you could do. But this is the basis. So you have your inputs, relations and then based on how you can even test your operating leverage. How if your operating leverage is less, if you change the leverage, if your variable cost, as we said, if your variable cost is less just by 10% reduction in variable cost. You remember we had two million in the end of the year. A 10% reduction in variable cost means this goes down by 227, right? This is the 10% reduction in variable cost to 27. 10% reduction in variable cost, that means your fixed cost went up, right? Fixed cost, let me just say, your fix, let's make it easier. Fixed cost is 70% of the total cost, fixed cost. If my fixed cost is 70% of my total cost and I do a 10% increase in fixed cost, that means fixed cost goes from 70% to 77%, which means my variable cost will reduce by 7%. So let's say my variable cost reduces to 23. This is a 10% increase in fixed cost. Now let's see what happens to profitability. So your profitability moves up by two, your profit goes up to 252.167.82. So you'll have more fixed cost because I mean, you're really not making so much money. But if it reduced, this is what leverage, if your fixed cost was 70% and then you could do a sensitivity, but actually it'd be nice to do another webinar with sensitivity analysis and see how the effects are.  And it's very interesting what your model would tell you about your business. So maybe instead of having lots of fixed cost, maybe instead of having property, you could decide to go and lease and then do that leasing. Leasing would mean maybe your variable cost would go up. So all sorts of structures you could build.  We had any questions, you have any questions before I close the webinar. And let me see if I ask you a question. I have a small poll for you. Another poll, another question I want to ask you guys. Let's hold on a bit, let me see. So we have some 3% of us are modellers here. So let's see, another question I want to ask you. We talked about scenario and sensitivity analysis, but do you do scenario analysis? So how many of you do that? Because what I was trying to start to was the scenario analysis and sensitivity analysis. How many of you do that in your models? You build sensitivities when you finish your models. As part of your model anyway, you build sensitivity analysis and scenario analysis. You do? Okay, that's excellent. Super, super, super. So we have some really experienced models here. Very good. So here I've gone through the simple steps in the demo for revenue and cost modeling. So that's what we went through. We brought in our inputs, if you remember. We brought in our inputs. Then what did we do? We modeled revenue. Then we now model costs. And then we calculated profit. And then we now answer those questions of how we did for breakeven analysis. So really that is your webinar on breakeven analysis. We did a full demo for you. And thank you for joining us about financial modeling institutes. The exams are in October, 2018, as I said. And you can register for the September 2018 EFM course we have, which is the detailed five day course, the detailed two week online pre-course. You will do a mock exam and then you do the final exam. You should be ready for the exam. You need to practice a lot before the exam to make sure you pass. And this webinar was sponsored by D Brown Consulting. We do training, consulting and payroll services. And for our training services, we are partnered with financial modeling institutes. So we are training partners or training providers, the only one in Nigeria so far. And we kind of sponsor lots of candidates to actually do the exam. So if you can, if you want to be sponsored for the exam, you let us know. We see if we can sponsor you for the exam as well. Send an email to training at dbrownconsulting.net. That's training at dbrownconsulting.net. We're also Microsoft partners. I'm also a Microsoft MVP. And the ATD Association for Talent Development. So we have very good experts in talent development, how to create courses, instructional design, master trainers, and that's the kind of people we have. And then classroom trainings. We have online training on Office Training Hub. And we have classroom training where we concentrate on the analysts, really. Excel for business, financial analysis, Office 365, financial modeling, and then Power BI and business intelligence courses. So those are the things we do.  These are our contact details. We are 0700 training is our call. You can just dial 0700 8724 6464. Or if you're outside Nigeria, you dial plus 234 700 training or plus<PHONE_NUMBER> 6464. Or email us at training at dbrownconsulting.net. Or go to our website, dbrownconsulting.net. Or go online to our training platform, which is www.officetraininghub.com. So we'd love to see you there and see you next month where we have another version of this webinar every month, every third Thursday of the month from 11 o'clock to 12 o'clock Central African time. And we have this financial modeling webinars every third Thursday of the month. So in the next couple of days, you can register for the next one. So if you've already registered, you've already be registered for the next one. You get an email. So glad to see you guys here today. And hopefully we'll see you again next month. This webinar will be posted on our YouTube channel in a couple of days. Go check it out. Thank you guys and bye-bye. Hope you enjoyed it.


Hi, sorry to bother you sir, but I'm looking for a Todd snap that's what the government calls me Oh, I'm so sorry. I guess my pictures. It's a little out of date. Yeah Well, who hasn't had a rough year or two here or there? Okay. What do you want? I uh, I got a job I got to do I'm your new apprentice Professor mirror should have mentioned I would be by yeah, he might have I'm not usually listening when he's yapping But you know what sure why not?  I promise sir I won't let you down. Nah, our buck got him Hey, get down here rule number one be discreet What's your password like? These are some shots from my portfolio. I'm pretty proud of Nobody would tell you how to take a picture. Jeez Poke one's barely in the frame in this one Just miss what no that's a basic rule of third shot It balances the composition for better visual interest that is the biggest load of Bufalon I have ever heard you know what you do need my help so listen up Why don't look at me like that. It's just a hyper potion. Is that even safe? Maybe all right, but first category Placement we've already gone over this smack dab in the middle of the frame none of that thirds or quarters business Okay, fine. I suppose it's more of a clinical assignment. So Sure, that's more like it. All right next category size pop with squirt How big should the subject be big enough to show detail but not big enough to dominate the shot wrong? You need to get all up in those grills if I cannot see straight down that quagsire's nostrils and into its brain You were not close enough. Okay, that can't be right That's so invasive and that brings me to my last category pose Oh student of infinite wisdom. Tell me what kind of pose is best my education tells me I want as natural a pose as possible, but my gut tells me you're about to tell me I'm wrong wrong wrong wrong Arceus they're filling your generation's head with filth No, listen, we want the subject to be doing as outrageous the thing as possible Anybody can get a shot of a light bird sleeping. What's the point if it's not rampaging or being hurled in the middle of a twister or something? Oh, and if it's just sitting there I'm just supposed to wait until it has a mental break and attacks.  I know right back when I was learning we used racks But then the safari zone had to go and make the news and ruin that for all of us You know what? I think I'm better off on my own I respect what you did in the past, but you are a disgrace to ecological surveys survey There's a no survey. Then what are you doing out here?  How about me any comment? Okay, can help me. You gotta help me kid. Hey everyone. Thanks for watching We would like to give a big shout out to our fan Alec who suggested a Pokemon snap video Do you want to be cool like Alec? Of course you do if you donate to our patreon You too can suggest a video that we will turn into a sketch You can go to patreon.com slash door monster not only donate for that But also to hang out with us monthly at pizza time and there's a couple other cool tears check them out It's great another big shout out to our friend Aaron who played the photographer in this video not the greasy one That was me. She was the cool one She has an Etsy where she makes super cute little stickers and magnets. Aren't these adorable? They are Check it out. You can find her Etsy at Murphu in me are f you and Ethan has put the URL right here for you to click on But don't don't don't click on it here because that's it's a video just pause you should click on in the description below this


Good morning, MizzlesCon! It's really hard to see you with all this light, but I hope you're all awake. Who's awake? Not so many people. I was actually wondering what your wishes are. So if we had the option of either starting earlier and having more content, more cool town halls, more Mizzles University sessions, or starting an hour later and sleep longer and therefore have more fun the evening before. Who would be for the option of sleeping longer? About half the people. And who would actually like to get up earlier and learn more at MizzlesCon? Oh yeah, also half. Okay, so probably we're just going to stick to the schedule in the middle to fit both interests here. So yesterday was already a pretty cool day. I must actually admit I wasn't here at MizzlesCon yesterday because it was at the Spark Summit in Prague, but I heard there was a lot of great stuff going on, the town halls, one Mizzles University session. Yesterday we had the SMAC track, we had an operations track, and we had the Mizzles Internals track, which usually is my favorite. And today we'll actually continue with this cool program. So today we have some more talks about SMAC and actually machine learning with some pretty cool new announcements as well. Then we have another session of the operations track, and we actually have our frameworks track where we're going to talk about Marathon and other frameworks running on top. So I feel this is a pretty packed program, so it's good that we're actually starting this early. But before we get started there, we actually have our keynote sessions in this morning. And here I would actually like to welcome my colleague on stage, Ariax. He's going to talk about the future of Mizzles and DCS and has some pretty neat and cool announcements, in my opinion. Let's welcome him on stage.


Hello and welcome to this session in which we will discuss the concept of contract asset and contract liability. Now from the word contract usually what we are dealing with is construction contract or long-term project. It doesn't have to be construction but some sort of a project that's going to take several years and that's why the word contract is there because usually when you have a long-term project you will sign a contract between two parties and as a result we could have a contract asset or a contract liability. Now the best way to illustrate this concept of contract asset and contract liability is to walk you through an example illustrating how these accounts come into place, how these accounts such as contract asset contract liabilities are created. So let's assume I entered into a non-cancelable agreement and that's important non-cancelable to build the customized equipment for half a million and the customer is Adam company. So that's the deal. The agreement stipulate that I will receive 20% after signing the agreement. So after I sign the agreement Adam will have to pay me $100,000. So what's going to happen is this I'm going to have to invoice Adam because otherwise the one's going to pay you unless you invoice them. So I have to invoice them. I have to create an invoice and send it to Adam for $100,000. Now although I invoice for $100,000 I did not do any work yet. Here we have the creation of a contract liability. I did not do the work yet but I invoice them but now I have the obligation to do the work. So think of contract liability. You can think of it as an earned revenue and you're going to see at the end of the day it looks and acts like an earned revenue but when I sign this contract and I send the invoice well what's going to happen is this I'm going to be expecting Adam company to send me $100,000. Therefore I will debit receivable $100,000 and I will credit a liability of $100,000. So what I did I said I have a liability now of $100,000. I expect Adam to send me a check of $100,000. Now a week 10 days later or the following day whatever that time is I receive the check. I receive that money from Adam company. What would I do then? I will debit the cash $100,000 and I will remove the receivable. So notice what happens. At the end of the day when all said and done all what I have left on my books for now is the cash for $100,000 sitting in the bank account and I have a contract liability so I want you to kind of make a T account about contract liability and put in there $100,000. I don't have to tell you it's a liability. It says right there contract liability but that contract liability is for work needs to be performed. So what is a contract liability? So let's kind of define it a little bit more. It's the obligation. Now we have the obligation to do what? To do work for Adam company which is build the equipment to transfer goods or services to perform work and we already receive the fund or we have an unconditional promise to get the money before start the work, before starting the work. So this is what a contract liability is. We have an obligation. We either receive the fund or we have unconditional promise and that's why I emphasize the word non-cancelable agreement to tell you there is a promise and that promise is unconditional. We expect to receive the money, the agreement is signed and it's legally enforceable. So this is how a contract liability is created. Now the next thing we're going to look at is what's going to happen to the contract liability and how do we create a contract asset as part of this example. Before we proceed any further I have a public announcement about my company farhatlectures.com. Farhat accounting lectures is a supplemental educational tool that's going to help you with your CPA exam preparation as well as your accounting courses. My CPA material is aligned with your CPA review course such as Becker, Roger, Wiley, Gleam, Miles. My accounting courses are aligned with your accounting courses broken down by chapter and topics. My resources consist of lectures, multiple choice questions, true-false questions as well as exercises. Go ahead start your free trial today no obligation no credit card required. Now let's take a look at how a contract asset is created. Now remember I signed the agreement and I started the work and here's what I did. I'm going to incur costs, I incurred costs, I hired people, I hired contractors, I bought material, I bought supplies because I need to build that piece of equipment and overall for the first quarter I incurred $120,000 in cost. Remember the client already paid me 100,000 that's fine I am grateful for Adam but I had to incur more cost well I cannot build the client yet for the additional 20,000 they paid me 100,000 because I needed to work I needed to start the work but I incurred more cost I am not if I need material if I need supplies I'm not gonna wait I'm gonna have to incur that cost because I know I'm gonna get this money later but now says I incurred more than what I received I cannot build the client yet now why can't I build the client for that additional 20,000 it could be many reasons it could be part of the agreement I have to wait until the project is done that's a condition or it could be I can only build them on a yearly basis no I just I just finished the first quarter I have to wait until a year from the signing of the agreement or it could be I need to reach a certain milestone like for example 50% done of the work before I can build them for the additional funds whatever it is there is a condition and I cannot build the client that additional 20,000 now bear in mind I have to debit a total of 120 total of assets because this is how much I incurred so let's kind of keep on going remember I already did 120,000 worth of work and we're gonna assume this is all kind of revenue the 120,000 it's all revenue it could be more than 120 but let's assume it's 120 now the first thing I'm gonna do since I perform the work I'm going to debit my contract liability remove my liability for 100,000 and record 100,000 in revenue remember the contract liability that was created on the prior slide I told you to create a contract liability of 100,000 contract liability now I removed it I did the work I did this 100,000 worth of work for the cash that the customer paid me I'm gonna go a step further and tell you what's gonna happen to the cash remember they gave me 100,000 dollar in cash with that cash I bought material supplies and what I did for that I debited the asset I debited an asset account for 100,000 and I credited the cash because I'm assuming I'm building some sort of an inventory for Adam therefore I debit the asset so that's why whether it's material supplies payroll it's all debiting some sort of an asset so this is how I use the money how I use the money now I still have $20,000 because remember I build them for an additional $20,000 because I did I did the work I incurred the cost now the cost could be cash could be payable it doesn't really matter what do I do with this additional $20,000 that I cannot build the client yet so this is where contract asset comes into place I'm gonna have to debit contract asset which is unbilled account receivable if I can build them if I can build them it's easy if I can build them I will debit the account receivable the account receivable that we know and I credit sales revenue or just revenue let's keep it consistent revenue but I cannot debit account receivable because I cannot if I invoice them they're gonna be angry they're gonna be mad they're gonna be like well this is not the deal well you can bill me you know once 50% is done but I need on my books I need to to know how much do I still have of unbilled account receivable I know I'm going to receive the money because there's a condition that's the only thing that's stopping me from billing them therefore I'm gonna have to debit an account called contract asset $20,000 and I will credit revenue because I did the work so notice $100,000 of revenue $20,000 of revenue I have revenue of 120 now the revenue could be higher I just said I incurred 120 of course and I may assume it's revenue the revenue could be higher but the point is we don't have to worry about the amount of revenue specifically for now but I credit revenue so notice how the contract asset is created now once I can build them so let's take let's take this step further so you understand where this is gonna go once I can build the client let's assume I call the client said look I incurred additional $20,000 I would you mind if I bill you for that and if the customer said yeah sure why not go ahead and bill me for that if I can build them I'm gonna debit account receivable $20,000 and I will remove the contract asset of $20,000 so this asset is removed because now I can build them then once I receive the cash from them for that $20,000 I debit cash $20,000 and I will credit receivable $20,000 and voila account receivable is gone contract is gone all what I have left is cash of $20,000 revenue of $20,000 this is just taking it to the next step just to show you what's gonna happen to all of this information all of these accounts so what is a contract asset well simply put we have the right we how do we have the right we have some sort of a non-cancelable agreement to receive funds in exchange for goods and services we have that right and we already performed the work but for some reason for some condition we cannot build the client at this time that's fine if we cannot build the client at this time because there's a condition guess what on our books we're gonna have a contract asset and we're gonna record the revenue but we cannot build the client it's not an account receivable now bear in mind if the condition to build the client has to do with the passage of time in other words the condition is that as time goes by I can bill you and as time goes by I can bill you then it will be receivable so just bear that in mind in case you get a multiple choice question about this but this is basically in a nutshell contract asset and contract liability I might work another example but this in this illustration I wanted to explain it how does it all come into how the how is it like how is it created or born how a contract liability is born for what reason how a contract asset is born and how does it go away what should you do now go to far hat lectures look at additional resources mcq's through false that's going to help you understand the revenue recognition contract asset contract liability IFRS 15 so on and so forth or the US standards for revenue recognition good luck everyone study hard and of course stay safe


Science 20 is I'm gonna walk you through how to get started with your unit C geology major project. So here I am in Google classroom, I'm signed in kind of in a test account so it should look like what a student would see. I'm gonna go into my science 20 class and you're gonna see here at the top of your feed the assignment hosted unit C geology project. You can also kind of go into class work there and see it as well. Gonna click on that. And here's the basic sort of instructions for the assignment. It does take the place of your unit C geology exam. So it's a big chunk of your grade. If you have any questions, email me right away and I will be very happy to help you out.  You will be working on this project independently not in a group. So please make sure that you are doing it on your own and your deadline is Wednesday, May 27th.  You're also gonna see a spot here for your name and a video link and you'll see why that is in a moment. So in this project, you're gonna make a model of a famous fault line and then you're gonna make a short video explaining your model. Here are the instructions. Step one, choose one of the three fault lines below. Now I have an example that I'm gonna show you of a little sample project I made. I didn't pick one of these three because I didn't want to sort of give away the answers but you can choose from any one of these three faults. They're all in North America, which is sort of nice. Once you've chosen one of the three fault lines and you might want to read up a little bit on each of those first to see which one is most interesting to you, you're gonna build a model. Now the model doesn't have to be super fancy, it can just be on a piece of paper, it's a drawing, some colors. We'll look at some examples here in a second. In your model, you need to show me relatively where it is. All right, I don't need like latitude and longitude but like what country is it in? Is it to a province or a city or a state or something like that?  So does one plate go underneath of another? Does the, do the plates go side to side? They move away from each other. We kind of learned about those different ways that tectonic plates move in the earthquake notes which if you're sort of like, I don't remember those earthquake notes back here in the Google classroom, I did include those in a PDF as well. You can go and check those again if you can't remember the different ways earthquakes move. Your diagram should also have other major geographic features near your fault like maybe there's an ocean nearby or a mountain range or a desert or a big lake or a river or something that sort of says, okay, this is where on earth it is.   What layer of the earth makes up the fault? If you're not sure about that, again, check those notes. What are the names the tectonic plates that make up the fault? And a little bit of Googling can really help you with that or there's also a diagram in the note can help you work that out. Can you show the way the fault moves then actually move your model physically so you can see that movement of the two plates? What type of fault is it? Is it a subduction fault, a strike slip fault, a normal fault, whatever the case may be? When was the last earthquake at this fault? Where was the epicenter of that earthquake and what was the richter magnitude of the earthquake? And a lot of times a little Googling will help you with that, you'll have to do a little bit of research but I've researched each of these three fault lines and those things pop up without too much effort and too much research. And lastly, you're gonna talk a little bit about how humans are impacted by this fault. Okay, what does life look like if you live along that fault? What kind of steps do you have to take to prepare for future earthquakes? Your video is gonna answer those seven questions. Of course, when you've got that done, you're gonna turn in this Google Doc by clicking that turn in button. Okay, a couple of notes, don't get discouraged if you're like, oh man, I don't have lots of materials at my house and I'm not very artistic, how can I make a model? It is okay just to do it even on a piece of paper. This is my example and the second that's what I did with a couple of colors to sort of show the different plates or mountain ranges or oceans or something like that. You can, though, get more creative if you have some materials at home and you'd like to do something out of some physical source of objects to make up the fault line, that is fine too. criteria for your video, try to keep it less than five minutes, I do have to watch a lot of these so it's nice if they're not too long. Make sure your video shows the movement of the fault line and some closeups maybe of the location so I can see the cities nearby or the states and some of those geographic features. Don't make it so far off that I can't read it in your video and you will need to verbally answer all of those seven questions. You do have to do a little bit of speaking here. How do you get your video to me? There's a few different ways. You can upload your video on YouTube and then once you've got that video uploaded on YouTube you can just go into this Google Doc and you can just paste that video link right here and I can click on the video link and I can watch it. And it's not hard to make a video private on YouTube that nobody else can see it if that's what you choose. Another way you can go through and do this is you can go and upload the video to your Google Drive and I'll show some examples of how to do that. It's not super hard. Just make sure your permissions are set if I can do your video, all right? So if you set your permission so that it's private then even if you hand it in, I can't see it. So make sure that I can see your video. Or if you've got some other method that's fine, send me an email and we can work that out. There's a rubric posted here in the Google Classroom that explains how you're gonna be marked so you can look at that, see what are the things you wanna make sure you have in your project. If you don't have access to technology to make a video, send me an email and we'll figure something out. Privacy concerns, don't worry. I'm not showing anyone in these videos other than me. And a couple of tips. If you're using a smartphone, I'm sure lots of you are filming landscape. That's sort of the view that's a little wider when you turn your phone on the side. That looks a lot better on a monitor.  And I've included a video here in the description that shows how to use that. It's pretty easy to do some simple little edits in it. Once your video is uploaded, you are going to put the link either for your YouTube link or your Google Drive link in here. Put your name in and then you're gonna go in and mark it as done. You can also add your video here if you have it as a Google Drive link already. And I can see it that way as well. Add any comments in that you want to and then I'll be able to mark this. Now, if you have any other questions about your video or the project in general, please make sure you ask. The due date is May 27th. Have fun. All right, this is an example of what your diagram model can look like for your unit C project. I chose a fault which you cannot choose. I chose the Hayward Fault which was not one of the examples I gave you but I wanted to show you one that would be similar to the ones you're doing but just not exactly the same. So the Hayward Fault is located in California. It is sort of just to the east of the city of Berkeley and to the city of Oakland and a little bit east and a little bit north of the city of San Jose as well. It is made up of the like all faults, the lithosphere, that's the crust which has been cracked and is forming the boundary between these two plates. You can see the movement of this plate and what I've decided to do here is just make my diagram and then cut it along the fault line. So what happens here is it moves like this. All right, so during an earthquake and actually it happens all the time just really, really slowly but it happens quickly during an earthquake. We get movement like this. So this plate, which is the Pacific plate mostly out in the ocean but also part of California moves northwest while at the same time the North American plate moves southeast. And so that's the movement of that boundary of this fault line. This is called a strike slip earthquake when we get the two sides moving kind of side to side compared to one another. The last earthquake that occurred along the Hayward Fault was in 1868. It was somewhere between a 6.5 and a 7.1 on the Richter scale because it was in 1868 and they didn't have the scale then and they don't know exactly for sure but that's based on predictions. The epicenter was in a really small town called Hayward, California, which was just past Oakland and San Jose so that's where it gets its name. About 30 people died in that earthquake and several buildings in San Jose and San Francisco collapsed as a result of it. The impact on people, another earthquake if it was to happen along the Hayward Fault line where there is a lot of industry, there's a lot of cities and infrastructure, it would affect the Bay Area water supply, there's a ton of cities down here and they have pipes transporting water, of course it would affect that so people would be without water. There's oil and gas pipelines running through here that would be disrupted. There are a lot of bridges in the Bay Area including the really famous San Francisco bridge which would be affected and highways and rail systems as well that would be down. Then slowly people are starting to retrofit bridges and buildings and things like that to try to prevent them against earthquakes. So this is what your project could look like. Those are the seven questions that I've answered that you're gonna answer as well from your project. You can do a diagram, you can do something more complicated, whatever you feel is best.