Tuesday, 26 December 2023

Living the Green Dream


Introduction: Meet George Kuzhivelil, a true inspiration for anyone seeking a sustainable lifestyle. For over a decade, he's been transforming his Kerala home into a green haven, proving that eco-friendly living is not just possible, but incredibly rewarding.

Solar Power Champion: In 2012, Dad's journey began with two solar panels. Fast forward to today, his rooftop boasts a 12-panel farm, silently capturing the sun's energy and lighting the way towards clean power.

Beyond Panels: Sustainability doesn't stop with electricity. Dad further reduced his environmental footprint by installing a solar water heater in 2016, ensuring a warm welcome while minimizing carbon emissions.


Rainwater Harvest: Monsoon showers aren't wasted in Dad's home. Four strategically placed rainwater harvesting tanks collect the bounty, providing abundant water for plants, gardens, and even car washes throughout the year.

Waste to Energy: Embracing sustainable waste management, Dad installed a biogas fuel system. This ingenious system not only recycles waste but also generates clean cooking fuel, reducing reliance on traditional, often polluting sources.

Giving Back to the Grid: In 2021, Dad reached a remarkable milestone – becoming a net contributor to the KSEB electricity grid. His solar panels now produce more than his home consumes, making him not just self-sufficient but also an active contributor to the community's clean energy future.

A Visionary Path: Importantly, Dad embraced these sustainable practices long before they became trendy. He's a true pioneer, demonstrating that living green is not just about following the latest fads, but about a genuine commitment to the planet and a vision for a brighter future.

Conclusion: Dad's story is an inspiring testament to the power of individual action. His dedication to sustainability showcases the positive impact we can all have on our environment, one step at a time. So, let's take a page from Dad's green playbook and start our own journeys towards a more sustainable future!

Monday, 2 October 2023

CASE Connected vehicles

The car of the future is connected, autonomous, shared, electric – and it’s already here. For example, by 2030, more than 95 percent of passenger miles will be served by autonomous cars. With sensors now built into every imaginable aspect of a vehicle, from fully voice-operated features and driver attention monitoring to biometric security for reducing theft, the possibilities for the customer experience are endless. Car manufacturers have started thinking beyond traditional car features like design and engine type to consider cutting-edge digital capabilities like personalized subscription services where user can opt in or out of a range of on-demand features from a centralized marketplace.

Because of this, customers have changed the way they purchase cars – it’s not just about aesthetics or performance anymore. There is a shift in customer preferences to include features like personalized digital entertainment and data-powered productivity. Connected cars of the future will also offer facial recognition systems that change in-car settings for the driver, in-car gesture control and voice recognition for advanced security, and in-car shopping with geo-based prompts.


Research indicates that the automotive industry is a leading adopter of smart factories and use of digital technologies such as IoT connectivity, intelligent automation, and cloud-based data analysis and management. However, to take advantage and truly commercialize on the possibilities of the connected vehicle, automotive leaders need to ensure they have a strong technological foundation and that they are:

  • Adopting next-gen capabilities that will drive innovation. This includes 5G, cloud, and AI. In fact, up to 15 percent of all new vehicles sold in 2030 could be fully autonomous using next-gen capabilities.
  • Conforming to safety and security demands. Given the sensors and the data-driven nature of connected vehicles, they may be more prone to hacking. But turning control completely over to software could lead to new hacking vulnerabilities and other liability issues that companies cannot ignore. To overcome this, automotive companies have to allow drivers to intervene in emergencies.
  • Choosing the right operating systems, hypervisor options, embedded software design, and hardware compatibility. These parameters are critical factors to consider given the increasing share of electrified vehicles as a percentage of new vehicle sales. For electrified vehicles, it’s important to have the right OS and embedded software and software.
  • Enabling rapid prototyping, development, and testing/verification. There’s no denying that the future of the automotive industryis tied closely to additive manufacturing. Continued innovations in the 3D printing industry – including new materials, printers, and techniques – will continue to change the way companies design and create. To remain competitive, or simply stay relevant, organizations need to adopt smarter and faster ways to prototype and develop.
  • Enhancing the capabilities behind design and production. A connected vehicle requires multiple end-to-end capabilities. The industry is in a critical period of disruption, and those who build in the software capabilities in the same way they think about hardware will be able to win mindshare and market share over the long term.
  • Think beyond the vehicle. For connected cars, the ecosystem is not just within the vehicle. Because of this, automotive manufacturers need to work with fleet suppliers and service providers to deliver sustainable, connected value across the ecosystem. For example, automobile manufacturers need to work with city planners for better sustainability options such as placement of electric vehicle charging stations based on data.

Tuesday, 18 July 2023

Java String Program - Part 1

 Program 1


Write a program in Java to accept a string in lower case and change the first letter of every word to upper case. Display the new string.
Sample input: we are in cyber world
Sample output: We Are In Cyber World

import java.util.Scanner;

class P1{
    
    public static void change(){
        Scanner sc = new Scanner(System.in);
        System.out.println("Enter a sentence");
        
        String s = sc.nextLine();
        String newstr = "";
        
        s = s.toLowerCase();
        s = s.trim();
        s = " " + s;
        
        for(int i=0; i<s.length(); i++){
            char ch = s.charAt(i);
            if(ch == ' '){
                newstr = newstr + ch;
                newstr = newstr + Character.toUpperCase(s.charAt(i+1));
                i++;
            }
            else {
                newstr = newstr + ch;
            }
        }
        
        System.out.println("new string = " + newstr);
    }
}

Program 2

Write a program to accept a string. Convert the string into upper case letters. Count and output the number of double letter sequences that exist in the string
sample Input: SHE WAS FEEDING THE LITTLE RABBIT WITH AN APPLE
Sample Output:4

import java.util.Scanner;

class P2{
    
    public static void countDouble(){
        Scanner sc = new Scanner(System.in);
        System.out.println("Enter a sentence");
        String s = sc.nextLine();
        
        int count = 0;
        
        s = s.toUpperCase();
        
        for(int i =0; i<s.length()-1 ; i++){
            char ch = s.charAt(i);
            char ch1 = s.charAt(i+1);
            if(ch == ch1){
                count++;
            }
        }
        
        System.out.println("count of double letter seq = " + count);
    }}
        

Program 3

Special words are those words which start and end with the same letter.
Example: EXISTENCE, COMIC, WINDOW

Palindrome words are those words which read the same from left to right and vice-versa.
Example: MALYALAM, MADAM, LEVEL, ROTATOR, CIVIC

All palindromes are special words but all special words are not palindromes.

Write a program to accept a word. Check and display whether the word is a palindrome or only a special word or none of them.

import java.util.Scanner;

class P3{
    
    public static void check(){
        Scanner sc = new Scanner(System.in);
        System.out.println("Enter a word");
        String w = sc.next();
        
        boolean isSpecial = false;
        boolean isPalin = false;
        
        // decide if the word is a special word
        
        char fc = w.charAt(0);
        char lc = w.charAt(w.length()-1);
        
        if (fc == lc)
            isSpecial = true;
            
        String rev = "";
        for(int i = w.length()-1; i >= 0; i--){
            rev += w.charAt(i);
        }
        
        if(w.equals(rev))
            isPalin = true;
        
        if( isSpecial && isPalin )
            System.out.println(w + " is special and palindrome ");
        else if(isSpecial)
            System.out.println(w + " is special");
        else if(isPalin)
            System.out.println(w + " is palindrome ");
        else
            System.out.println(w + " is neither special nor palindrome ");
        }}   


Video explanations for these programs 



 

            

            
            
        


Saturday, 15 July 2023

Java - Bubble Sort Numbers and Strings

Bubble sort code for sorting numbers in ascending order


import java.util.Scanner;
public class Bubble_Asc{
    public static void sort_number_asc(){
        // input array elements
        Scanner sc = new Scanner(System.in);
        int a[] = new int[5];
        System.out.println("Enter five array elements");
        for(int i=0; i<a.length; i++){
            a[i] = sc.nextInt();
        }
        
        // sort array elements 
        for(int i=0; i<a.length; i++){
            for(int j=0; j<a.length-1-i; j++){
                if( a[j]>a[j+1] ){
                    //swap elements
                    int temp = a[j];
                    a[j] = a[j+1];
                    a[j+1] = temp;
                }
            }
        }
        
        
        // output the sorted array
        System.out.println("Sorted array is");
        for(int i=0; i<a.length; i++){
            System.out.print(a[i] + " ");
        }
        
    }
}

Bubble sort code for sorting numbers in descending order

import java.util.Scanner;

public class Bubble_Desc{
    public static void sort_number_desc(){
        // input array elements
        Scanner sc = new Scanner(System.in);
        int a[] = new int[5];
        
        System.out.println("Enter five array elements");
        
        for(int i=0; i<a.length; i++){
            a[i] = sc.nextInt();
        }
        
        // sort array elements 
        for(int i=0; i<a.length; i++){
            for(int j=0; j<a.length-1-i; j++){
                if( a[j]<a[j+1] ){
                    //swap elements
                    int temp = a[j];
                    a[j] = a[j+1];
                    a[j+1] = temp;
                }
            }
        }
        
        
        // output the sorted array
        System.out.println("Sorted array is");
        for(int i=0; i<a.length; i++){
            System.out.print(a[i] + " ");
        }
        
    }
}


Bubble sort code for sorting strings in ascending order

import java.util.Scanner;

public class Bubble_Asc_Strings{
    public static void sort_string_asc(){
        // input array elements
        Scanner sc = new Scanner(System.in);
        String a[] = new String[5];
        
        System.out.println("Enter five array elements");
        
        for(int i=0; i<a.length; i++){
            a[i] = sc.next();
        }
        
        // sort array elements
        for(int i=0; i<a.length; i++){
            for(int j=0; j<a.length-1-i; j++){
                if( a[j].compareTo(a[j+1])>0 ){
                    //swap elements
                    String temp = a[j];
                    a[j] = a[j+1];
                    a[j+1] = temp;
                }
            }
        }
        
        
        // output the sorted array
        System.out.println("Sorted array is");
        for(int i=0; i<a.length; i++){
            System.out.print(a[i] + " ");
        }
        
    }
}
        
        

Bubble sort code for sorting strings in descending order

import java.util.Scanner;

public class Bubble_Desc_Strings{
    public static void sort_string_desc(){
        // input array elements
        Scanner sc = new Scanner(System.in);
        String a[] = new String[5];
        
        System.out.println("Enter five array elements");
        
        for(int i=0; i<a.length; i++){
            a[i] = sc.next();
        }
        
        // sort array elements
        for(int i=0; i<a.length; i++){
            for(int j=0; j<a.length-1-i; j++){
                if( a[j].compareTo(a[j+1])<0 ){
                    //swap elements
                    String temp = a[j];
                    a[j] = a[j+1];
                    a[j+1] = temp;
                }
            }
        }
        
        
        // output the sorted array
        System.out.println("Sorted array is");
        for(int i=0; i<a.length; i++){
            System.out.print(a[i] + " ");
        }
        
    }
}

Youtube video link explaining the above code is



 











        
             
                
        

Monday, 10 July 2023

Java - Class based program

 Program 1 - Eshop




import java.util.*;

class Eshop {
    String name;
    double price;
    
    void accept(){
        Scanner sc = new Scanner(System.in);
        System.out.println("Enter name and price");
        name = sc.next();
        price = sc.nextDouble();
    }
    
    void calculate(){
        if (price >= 1000 && price <=25000)
            price = price - 0.05 * price;
        else if (price >= 25001 && price <= 57000)
            price = price - (7.5/100.0) * price;
        else if (price >=57001 && price <= 100000)
            price = price - (10/100.0) * price;
        else 
            price = price - (15.0/100.0) * price;
    }
    
    void display(){
        System.out.println("name = " + name);
        System.out.println("net amount to be paid = " + price);
    }
    
    public static void main(){
        Eshop obj = new Eshop();
        obj.accept();
        obj.calculate();
        obj.display();
    }
}

/* Variable Description Table

Variable        Type        Use
name            String      to store name of product
price           double      to store price of product

*/


 Program 2 - CabService



    
import java.util.Scanner;

class CabService{
    // member variables
    
    String car_type;
    double km;
    double bill;
    
    // member methods
    
    CabService(){
        car_type = "";
        km = 0.0;
        bill = 0.0;
    }
    
    void accept(){
        Scanner sc = new Scanner(System.in);
        System.out.println("Enter car_type and km");
        car_type = sc.nextLine();
        km = sc.nextDouble();
    }
    
    void calculate(){
        if (car_type.equals("AC CAR"))
        {
            if (km<=5){
                bill = 150;
            }
            else {
                bill = 150 + (km - 5) * 10;
            }
        }
        else if (car_type.equals("NON AC CAR"))
        {
            if (km<=5) {
                bill = 120;
            }
            else {
                bill = 120 + (km - 5) * 8;
            }
        }
    }
    
    void display (){
        System.out.println("CAR TYPE: " + car_type);
        System.out.println("KILOMETER TRAVELLED: " + km);
        System.out.println("TOTAL BILL: " + bill);
        
    }
    
    public static void main(){
        CabService obj = new CabService();
        obj.accept();
        obj.calculate();
        obj.display();
    }
}

/*

Variable    Datatype    Usage
car_type    String      used to store cartype
km          double      used to store kilometre
bill        double      used to store bill amount
obj         CabService  object used to invoke methods

*/
      

Program 3 - employee


import java.util.Scanner;
class employee{
    // member variables
    
    int eno;
    String ename;
    int age;
    double basic;
    double net;
    
    // member methods
    
    void accept(){
        Scanner sc = new Scanner(System.in);
        System.out.println("Enter eno, ename, age, basic salary");
        eno = sc.nextInt();
        ename = sc.next();
        age = sc.nextInt();
        basic = sc.nextDouble();
    }
    
    void calculate(){
        double hra = 18.5/100.0 * basic;
        double da = 17.45/100.0 * basic;
        double pf = 8.10/100.0 * basic;
        net = basic + hra + da - pf;
        // net = basic + (18.5/100.0*basic) + (17.45/100.0 * basic) - (8.10/100.0 * basic);
        if (age > 50)
        {
            net = net + 5000;
        }
    }
    
    void print(){
        System.out.println("eno \t ename \t age \t basic \t net");
        System.out.println(eno + "\t" + ename + "\t" + age +
                           "\t" + basic + "\t" + net );
     }
     
     public static void main(){
         employee obj = new employee();
         obj.accept();
         obj.calculate();
         obj.print();
        }
    }

/* Variable description table

Variable    Datatype    Usage
eno         int         used to store employee no
ename       String      used to store name
age         int         used to store age
basic       double      used to store basic salary
net         double      used to store net salary

*/
         

Explanation of above code can be found at


                    

        

        

        

        

        

        

        

    

  

        
        
    
        
        
        
        
        
        
    
    
    
    
    
    
     
    
    
    
    
    
    
        
        

Monday, 19 June 2023

How can CSPs monetize 5G

The advent of 5G technology is currently revolutionizing various industries by facilitating connected vehicles, smart cities, industry 4.0, connected health, and other immersive applications worldwide. Numerous businesses, particularly large tech companies, are developing value-added services that utilize 5G broadband to enhance operations and provide users with exceptional experiences.

Communication Service Providers (CSPs) must seize this opportunity to capitalize on 5G broadband by creating value-added services. This not only allows them to cater to mobile B2C customers but also enables them to diversify their business, establish predictability, and promptly respond to customer needs. Furthermore, it opens up avenues to target specific vertical markets and foster B2B and B2B2X ecosystems.

To thrive in this landscape, CSPs need to go beyond merely selling broadband and instead provide services that deliver tangible value, capitalizing on the enhanced speed and reliability of 5G in industries such as automobiles, utilities, and healthcare.

However, the challenge lies in the limitations imposed by legacy network infrastructure, hindering their progress. The growing demand for bandwidth is straining existing infrastructure, necessitating the migration to Software Defined Networks (SDNs) for improved network reliability. Additionally, Network Function Virtualization (NFV) enables the expansion of network capabilities. Addressing the legacy issue also calls for the implementation of a new service orchestration layer atop the network, offering an avenue to effectively monetize the capabilities of 5G.

Service orchestration entails the ability to create, oversee, and integrate diverse network elements into a marketable product for customers. Since the needs of different industries vary, the underlying services must be provisioned dynamically, adapting to changes in resilience, security, and routing capabilities. Communication Service Providers (CSPs) should possess reusable cloud-based services that can be easily deployed, packaged, and offered as tailored solutions for specific use cases within various sectors like Connected Health or Smart Cities.

By adopting a cloud-native approach, these services become portable, scalable, and more resilient compared to monolithic applications. They operate proactively and respond to events, automating business workflows and simplifying order tracking, failure management, fallout handling, and diagnostics for repairs.


For instance, within the realm of smart devices and IoT sensors, telecommunications companies (telcos) can develop applications that leverage IoT data from factories to provide asset monitoring, predictive maintenance, and enhanced sustainability. This empowers manufacturing customers with valuable insights to drive actionable decisions. Additionally, CSPs can collaborate with automobile manufacturers to create in-car commerce use cases, such as online ordering, in-car payments, and geofencing for curb-side pickups, seamlessly integrated within the infotainment systems.

Saturday, 11 February 2023

Architecting a Point of Sales application for the Edge

 Edge computing is a computing architecture that moves data processing and storage from centralized systems to the edge of the network. In a Point of Sales (POS) system, this can bring several advantages, such as:


Latency reduction: By processing data at the edge, latency is reduced, making transactions faster and more efficient.


Improved reliability: With edge computing, the system can operate even if there is a failure in the central system, making the system more reliable.


Increased security: By processing data at the edge, the risk of data breaches is reduced as the data is not transmitted to a centralized location.


Offline operation: In the event of a network failure, edge computing can allow the POS system to continue operating, reducing downtime and providing a better customer experience.


Scalability: Edge computing makes it easier to scale the system as needed, making it more flexible to meet changing business needs.


When considering edge computing for a POS system, some key factors to consider include:


Network connectivity: The system must be able to connect to the edge devices, such as mobile devices, payment terminals, and sensors.


Code and data deployments: A mechanism is needed to deploy the latest code features and upgrades as well as the core data from the 


Data processing: The system must be able to process large amounts of data in real-time at the edge.


Data storage: The system must be able to store data at the edge, either locally or in the cloud.


Security: The system must be secure, protecting sensitive customer data and ensuring that transactions are protected from cyber-attacks.


Integration with existing systems: The system must be able to integrate with existing systems, such as inventory management and customer relationship management 


Wednesday, 1 February 2023

Security testing in DevOps CI CD

 Security testing in DevOps CI/CD involves integrating security practices and tests into the continuous integration and continuous deployment (CI/CD) pipeline. Here are some steps to perform security testing in DevOps CI/CD:


1. Define security requirements: Determine the security requirements for your application or system. Identify the areas that need testing, such as authentication, authorization, data protection, input validation, and secure configurations.


2. Integrate security tools: Identify and integrate security testing tools into your CI/CD pipeline. These tools can include static application security testing (SAST), dynamic application security testing (DAST), container scanning, vulnerability scanning, and code analysis tools. Popular security tools include OWASP ZAP, SonarQube, and Nessus.


3. Automated security tests: Develop automated security tests that can be run as part of the CI/CD pipeline. These tests should check for common security vulnerabilities, such as SQL injection, cross-site scripting (XSS), insecure direct object references, and insecure deserialization. Implement these tests using frameworks like JUnit, Selenium, or dedicated security testing frameworks.


4. Infrastructure as Code (IaC) security: If you are using infrastructure as code (IaC) tools like Terraform or CloudFormation, incorporate security checks for your infrastructure code. Ensure that security best practices are followed, such as encrypting sensitive data, setting appropriate access controls, and configuring secure network configurations.


5. Secure configurations: Implement secure configuration management practices in your CI/CD pipeline. This includes ensuring that default passwords are changed, unnecessary services and ports are disabled, and secure communication protocols are used.


6. Secure artifact management: Ensure that your CI/CD pipeline handles artifacts, such as build packages or container images, securely. Scan these artifacts for vulnerabilities and enforce secure storage and transmission practices.


7. Security code reviews: Integrate security code reviews into your development process. Involve security experts to review the code for potential security vulnerabilities, adherence to secure coding practices, and compliance with security standards.


8. Continuous monitoring: Implement continuous security monitoring in your production environment. This can include logging and monitoring of security-related events, intrusion detection systems, and vulnerability management. Use tools like ELK stack (Elasticsearch, Logstash, Kibana) or Splunk for centralized log management.


9. Security training and awareness: Provide security training and awareness sessions to your development and operations teams. Educate them about secure coding practices, common security vulnerabilities, and security best practices throughout the CI/CD pipeline.


10. Incident response and recovery: Develop incident response plans to handle security incidents that may occur during the CI/CD process. Define procedures for identifying, containing, investigating, and recovering from security breaches.


Remember that security testing is an ongoing process, and it should be integrated at every stage of the CI/CD pipeline. By adopting a security-first mindset and incorporating security practices into the DevOps workflow, you can help mitigate potential vulnerabilities and ensure a more secure software delivery process.

Tuesday, 3 January 2023

Restaurant Trends to focus in Customer Experience

In the competitive world of restaurants, it's important to constantly strive for innovation in order to attract and retain customers. 

One key area to focus on is the customer experience. Here are some ideas for how restaurants can innovate in this area:

Offering personalized recommendations: With the help of technology and AI, restaurants can now track customers' past orders and use that information to offer personalized recommendations for their next visit. This not only enhances the customer experience, but also helps to increase sales by showcasing menu items that the customer is likely to enjoy. Online ordering apps already do this by offering a choice to repeat their past as well as favourite orders. Restaurants can look for moving that capability in-house

Enhance the online ordering experience: With the rise of online food delivery platforms, it's important for restaurants to have a seamless online ordering experience. This can include offering easy-to-use mobile apps, clear menu descriptions and photos, and the ability to customize orders. Customers have frequently complained about online ordering processes where there are too many clicks to get to the final checkout - and this is a major metric tracked among ecommerce marketing teams.

Use technology to streamline the dining experience: There are now a number of technologies available that can help restaurants streamline the dining experience, such as self-order kiosks, mobile payment options, and table-side ordering provided by various vendors. These technologies can help to reduce wait times and improve efficiency, which can enhance the customer experience. However these are most effective when they connect with a single source of data from the restaurant Back of House ideally through APIs that provide the Menu, Pricing, Promotions, Customer, Loyalty and other required data.

Offer unique and memorable experiences: In addition to the food, restaurants can also focus on creating unique and memorable experiences for their customers. This can include things like hosting special events, offering live music, or partnering with local artists to showcase their work. Local produce can be highlighted. Patrons would be interested to visit restaurants that prioritize fresh and locally sourced ingredients as a niche value.

By constantly innovating and looking for ways to enhance the customer experience, restaurants can stand out in a crowded market and build a loyal customer base with returning customers. 

Wednesday, 21 December 2022

2022 Music Year in Review

 This is what happens when you have a shared Spotify account with the family