ICode9

精准搜索请尝试: 精确搜索
  • 面向对象---类与类的关系2022-09-15 21:31:00

    package com.gao.test.Test5; public class Girl { //属性 String name; // friend f; //与生俱来就有朋友(例子不太好,尽量理解,与生俱来的就可以设为属性) //有一个默认初始值是null,运行时有空指针异常 NullPointerException friend f = new frien

  • Java基础语法重点02(类型转换)2022-09-15 20:32:29

    类型转换 由于Java是强类型语言,所以要进行有些运算的时候,需要用到类型转换 类型转换: byte,short,char--->int--->long--->float--->double (低--------------------------------------------------高) 运算中,不同类型的数据先转换成同一类型,然后进行运算 强制转换:(类型)变量名

  • Vue computed() 简介2022-09-15 15:34:44

    computed() computed()计算属性。在setup内该函数返回ref类型,所以也是要求用.value取值,赋值。但在模板中可以自动解勾。 computed与methods的区别在于:computed是计算结果变化时触发,而methods是主动调用才触发。 computed与watch区别:watch类似于定时侦听变量,它很耗资源。而computed

  • 9.152022-09-15 13:00:21

    height=1.68print("你的身高:"+str(height))weight=62print("你的体重:"+str(weight))bmi=weight/(height*height)print("你的BIM指数是:"+str(bmi))# 判断身材是否合理if bmi<18.5: print("你的体重过轻")if bmi>=18.5 and bmi<=24.5: print(&qu

  • 第二章 Python语言基础2022-09-15 01:02:06

    实例01 根据身高、体重计算BMI指数 运用公式 “ BMI=体重/(身高 × 身高)” 点击查看代码 height = 1.67 #保存身高的变量,单位:米 print("您的身高:" +str(height)) weight = 60 #保存体重的变量,单位:千克 print("您的体重:" +str(weight)) bmi=weight/(height*height)

  • python基础学习2022-09-14 23:00:09

    一·根据身高,体重计算BMI指数 height=1.70print("您的身高:"+str(height))weight=48.5print("您的体重:"+str(weight))bmi=weight/(height*height)print("您的BMI指数为:"+str(bmi))if bmi<18.5: print("您的体重过轻:")if bmi>18.5 and bmi<24.9:

  • The first assignment2022-09-14 22:34:38

    实例01 code01: height = 1.70print("您的身高:"+str(height))weight = 48.5print("您的体重:"+str(weight))bmi=weight/(height*height)print("您的BMI指数为:"+str(bmi))#判断身材是否合理if bmi<18.5: print("您的体重过轻 ~@_@~")if bmi>=18.5 and bm

  • Python 第二章实验2022-09-14 22:32:31

    height=1.7 #保存的身高的变量, 单位:米 print("您的身高:" + str(height)) weight = 100 print("您的体重:" + str(weight)) #保存的体重的变量,单位:kg bmi=weight/(height**2) #用于计算BMI指数,公式:BMI=体重/身高的平方 print("您的

  • python第二章实例2022-09-14 22:00:25

    实例01 根据身高、体重计算BMI指数,代码如下: height =float(input("请输入你的身高:")) weight =float(input("请输入你的体重:")) bmi =weight/(height*height) #判断身材是否合理 if bmi<18.5: print("您的BMI指数为:"+str(bmi)) print("体重过轻~@_@~") if bmi>=1

  • 13 刘欣晨2022-09-14 19:02:01

    实验 一  项目名称:根据身高、体重计算BMI指数 实验内容: height = 1.70 print("您的身高:" + str(height)) weight = 48.5 print("您的体重:" + str(weight)) bmi=weight/(height+height) print("您的BMI指数为:"+str(bmi)) #判断身材是否合理 if bmi<18.5:     print("您的体重过

  • 第2章2022-09-14 12:31:25

    example 1.bmi height =1.70print("您的身高:" + str(height))weight = 48.5print("您的体重:" + str(weight))bmi = weight/(height*height)print("您的BMI指数为:"+str(bmi))#判断身材是否合理if bmi<18.5: print("您的体重过轻 ~@_@~")if bmi>=18.5

  • PythonUnit2实例2022-09-13 23:33:51

    实验 1  项目名称:  python语言基础                                 实例一: height=1.70 print("您的身高:"+str(height)) weight=48.5 print("您的体重:"+str(weight)) bmi=weight/(height*height) print("您的BIM指数为:"+str(bmi)) #判断身

  • 编程2022-09-13 23:00:59

    height = 1.70 print("您的身高: " + str(height)) weight = 48.5 print("您的体重: " + str(weight)) bmi=weight/(height*height) print("您的BMI指数为:"+str(bmi)) # 判断身材是否合理 if bmi<18.5: print("您的体重过轻 ~@_@~") if bmi>=18.5 and

  • Python02代码2022-09-12 23:30:21

    实例1 height = 1.65 print("你的身高:"+str(height)) weight = 45.5 print("你的体重:"+str(weight)) bmi=weight/(height*height) print("你的BMI指数为:"+str(bmi)) #判断身材是否合理 if bmi<18.5:     print("你的体重过轻 ~@_@~") if bmi>=18.5 and bm

  • redis的事务与乐观锁2022-09-12 14:34:47

    redis的事务与乐观锁 redis事务的本质是一组命令的集合,事务支持一次执行多条命令,一个事物中所有命令都会被序列化,在事务执行时,会按照之前的顺序串行执行队列中的命令,其他客户端提交的命令不会插入到事务的执行队列中去。 redis事务的本质 redis事务是一次性,顺序性,排他性的执行一

  • Day072022-09-09 07:30:09

    package base;public class Day06 { public static void main(String[] args) { //操作比较大的时候,注意溢出问题 //JDK7新特性,数字之间可以用下划线分割 int money =10_0000_0000; int years =20; int total =money*years;//-1474836480,计算的时候溢出了 l

  • NC24416 [USACO 2013 Nov G]No Change2022-09-04 03:00:51

    题目链接 题目 题目描述 Farmer John is at the market to purchase supplies for his farm. He has in his pocket K coins (1 <= K <= 16), each with value in the range 1..100,000,000. FJ would like to make a sequence of N purchases (1 <= N <= 100,000), where

  • cur·ren·cy2022-08-27 08:00:24

    Origin: currentia 'flowing', from Latin currere; current A currency in the most specific sense is money in any form when in use or circulation as a medium of exchange, especially circulating banknotes and coins. A more general definition is that

  • cf675 C. Money Transfers2022-08-26 01:02:24

    题意: 给定大小为 \(n\) 的环,环上有和为 0 的 \(n\) 个整数(可能为负) 每次操作任选一位置 \(i\) 和整数 \(x\),令 \(a_i\) 加 x,相邻的一个书减 x。问至少几次操作可使所有数为 0 思路: 把环切成尽可能多的段,每段和为 0。答案就是 n-段数 正解是取出现次数最多的前缀和值就行了。 记录

  • 多线程.线程同步2022-08-18 03:00:36

    同步方法:synchronized 同步块:synchronized(Obj){} 并发:多个线程操作同一个资源 队列和锁 每个对象都有一个锁,sleep不会释放锁 由于同一进程的多个线程共享同一块存储空间,在带来方便发同时,也带来了访问冲突问题,为了保证数据在方法中被访问时的准确性,在访问时加入锁机制synchroniz

  • 互斥锁、线程、GIL2022-08-10 23:01:51

    目录作业讲解互斥锁一、作用二、代码演示三、强调线程理论一、前提进程:是资源单位线程:是执行单位二、多进程和多线程的区别三、特点四、创建线程的两种方式五、多线程实现TCP服务端并发六、join方法1.作用2.代码演示七、同一个进程下的线程共享数据一、代码演示'''多线程''''''多

  • ef core 数据类型和表字段名设置2022-08-10 19:31:44

    HasColumnType HasColumnType是指定字段类型 [Column(TypeName = "decimal(18, 2)")] public decimal Money { get; set; } 等同于 builder.Property(a => a.Money).HasColumnType("decimal(18, 2)"); HasColumnName HasColumnName是指定表字段名 比如说属性名字叫Money,但是你希

  • 强制转换2022-08-07 12:01:28

    /*1. 不能对布尔值进行转换2.不能吧对象类型转换成不相干的类型3.在把高容量转换到低容量的时候需要强制转换4.转换的时候可能存在内存溢出,或者精度问题(就是小数的时候转成整数int) */System.out.println((int)23.4);System.out.println((int)23.56);System.out.println("=========

  • Java开发学习(二十二)----Spring事务属性、事务传播行为2022-08-05 09:01:57

    一、事务配置 上面这些属性都可以在@Transactional注解的参数上进行设置。 readOnly:true只读事务,false读写事务,增删改要设为false,查询设为true。 timeout:设置超时时间单位秒,在多长时间之内事务没有提交成功就自动回滚,-1表示不设置超时时间。 rollbackFor:当出现指定异常

  • JavaSE自学小练习(判断与循环)2022-08-01 17:31:26

    题目来源:https://space.bilibili.com/37974444?spm_id_from=333.337.0.0 一、if判断语句 题目1 李雷想买一个价值7988元的新手机,她的旧手机在二手市场能卖1500元,而手机专卖店推出以旧换新的优惠,把她的旧手机交给店家,新手机就能够打8折优惠。为了更省钱,李雷要不要以旧换新?请在控制

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有