Ask a Question
Ask Question Login
Corporate Training
  1. Community
  2. Natun Yadav

Natun Yadav

Community Learner
Share
8Questions
8Answers
10.0KViews on questions

How to condense if/else into one line in Python?

In Python, you can condense an if/else statement into a single line using what's called a ternary conditional operator. This is a clean and readable way to assign a value or return a result based on a condition without writing a full multi-line if/else block. Syntax: value_if_true if condition else value_if_false…

Python

Answered May 15, 2025 · 1.1K Views Read answer →

Explain the Plundervolt attack.

Plunder Volt is a vulnerability in Intel CPUs. These CPUs allow users to use privileged software interfaces to undervolt their CPU. Undervolting is the process of supplying the CPU with less power than specified, usually in order to conserve power. In this case, undervolting is used to induce faults into calculations.…

Web-development

Answered Oct 17, 2022 · 1.2K Views Read answer →

Give a detailed description of the Java GPA calculator.

For the Java GPA calculator - Since the letters and symbols we're dealing with are relatively close to each other in terms of character value, we can use that to our advantage by doing some simple maths. NOTE: This code is largely unchecked and rather verbose - optimise as desired class Student { private double points…

Java

Answered Oct 12, 2022 · 1.1K Views Read answer →

SOQL: Convert set to list

To convert set to list, their is no need to work with lists and sets if you group-by in the query: public List getItems() { List options = new List(); for(AggregateResult l : [SELECT Name FROM License__c GROUP BY Name]){ options.add(new SelectOption(String.valueOf(l.get('Name')),String.valueOf(l.get('Name')))); }…

SQL Server

Answered Jul 29, 2021 · 1.0K Views Read answer →

Explain how apply() and lapply() function works in R.

Apply() function works by considering input as a data frame or a matrix and gives an output as a vector, list or an array. apply() function basically takes 3 arguments which are Array or a matrix A value to define the function A function to apply. lapply() function works only on lists and it also returns output as a…

Data Science

Answered Nov 19, 2019 · 1.3K Views Read answer →

How to perform z-test and t-test using R? Explain with an example

To perform z- test, let us take data first. ############## 1 sample z test ########## fabric=read.csv(file.choose()) Fabric Here fabric is the dataset Now to perform Normality test, we can perform Anderson-Darling Test which is the following ##### Normality Test################## library(nortest) ad.test(

Data Science

Answered Nov 13, 2019 · 1.4K Views Read answer →

More members from the Data Science community

Learners asking and answering questions on the same topics — follow their questions and join in.

Latest Data Science Blogs

Guides, tips and career advice on Data Science from JanBask experts.

Learn & Explore

Free tutorials and interview questions from industry experts — learn the skill, then get ready to prove it.